diff --git a/ts/Bootstrap.ts b/ts/Bootstrap.ts index 8b742d9..9f60244 100644 --- a/ts/Bootstrap.ts +++ b/ts/Bootstrap.ts @@ -136,15 +136,15 @@ export default class Bootstrap { } private async onUserRequestsToGoOnline() { - if (!Storage.get().getItem('serverIsOmniscient') && OJSXC_CONFIG.serverType !== 'internal') { - this.jsxc.showLoginBox(); - - return; - } - try { let settings = await Settings.loadConnection(undefined, undefined); + if (!Storage.get().getItem('serverIsOmniscient') && OJSXC_CONFIG.serverType !== 'internal') { + this.jsxc.showLoginBox(); + + return; + } + if (!settings) { throw new Error('No settings provided'); }