Do not block for device manager to become ready
Summary: ^ Also, if an error happens, do not swallow it, rethrow. Reviewed By: passy Differential Revision: D49912780 fbshipit-source-id: 30451110d8c5776e2b0826d6e924ab5fe98cd7e2
This commit is contained in:
committed by
Facebook GitHub Bot
parent
80fc8eb4ed
commit
0e90873096
@@ -199,13 +199,17 @@ export class FlipperServerImpl implements FlipperServer {
|
|||||||
await this.createFolders();
|
await this.createFolders();
|
||||||
await this.server.init();
|
await this.server.init();
|
||||||
await this.pluginManager.start();
|
await this.pluginManager.start();
|
||||||
await this.startDeviceListeners();
|
|
||||||
|
this.startDeviceListeners();
|
||||||
|
|
||||||
this.setServerState('started');
|
this.setServerState('started');
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
if (!isHandledStartupError(e)) {
|
if (!isHandledStartupError(e)) {
|
||||||
console.error('Failed to start FlipperServer', e);
|
console.error('Failed to start FlipperServer', e);
|
||||||
}
|
}
|
||||||
this.setServerState('error', e);
|
this.setServerState('error', e);
|
||||||
|
|
||||||
|
throw e;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user