Fix Flipper lints #3

Summary: More error chaining and some error logging.

Reviewed By: lblasa

Differential Revision: D30932120

fbshipit-source-id: de0da698a24b04312b4df3c59b02d8d85d2d7e19
This commit is contained in:
Pascal Hartig
2021-09-14 08:54:22 -07:00
committed by Facebook GitHub Bot
parent 384fd5ab1d
commit f522c9ee07
2 changed files with 3 additions and 0 deletions

View File

@@ -65,6 +65,8 @@ export async function checkForUpdate(
console.log('Skipping version check on non-authenticated network.'); console.log('Skipping version check on non-authenticated network.');
return {kind: 'up-to-date'}; return {kind: 'up-to-date'};
} }
// Good use of nesting.
// eslint-disable-next-line promise/no-nesting
return res.json().then(parseResponse); return res.json().then(parseResponse);
default: default:
const msg = `Server responded with ${res.statusText}.`; const msg = `Server responded with ${res.statusText}.`;

View File

@@ -285,6 +285,7 @@ export class FlipperPlugin<
} }
get device() { get device() {
// eslint-disable-next-line node/no-sync
return this.realClient.deviceSync; return this.realClient.deviceSync;
} }