1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-15 15:53:27 +00:00

init power monitor at end

This commit is contained in:
Kyle Spearrin
2019-03-11 23:18:04 -04:00
parent 6facf3f2cf
commit 8b68fa4ea0

View File

@@ -91,17 +91,17 @@ export class Main {
await this.i18nService.init(locale != null ? locale : app.getLocale()); await this.i18nService.init(locale != null ? locale : app.getLocale());
this.messagingMain.init(); this.messagingMain.init();
this.menuMain.init(); this.menuMain.init();
this.powerMonitorMain.init();
await this.trayMain.init('Bitwarden', [{ await this.trayMain.init('Bitwarden', [{
label: this.i18nService.t('lockNow'), label: this.i18nService.t('lockNow'),
enabled: false, enabled: false,
id: 'lockNow', id: 'lockNow',
click: () => this.messagingService.send('lockVault'), click: () => this.messagingService.send('lockVault'),
}]); }]);
await this.updaterMain.init();
if (await this.storageService.get<boolean>(ElectronConstants.enableStartToTrayKey)) { if (await this.storageService.get<boolean>(ElectronConstants.enableStartToTrayKey)) {
this.trayMain.hideToTray(); this.trayMain.hideToTray();
} }
this.powerMonitorMain.init();
await this.updaterMain.init();
}, (e: any) => { }, (e: any) => {
// tslint:disable-next-line // tslint:disable-next-line
console.error(e); console.error(e);