From 229f289d126b3b8aba269379e57972c77c1bfea6 Mon Sep 17 00:00:00 2001 From: Mikunj Date: Tue, 14 Apr 2020 12:23:39 +1000 Subject: [PATCH] Fix auto update not running correctly --- ts/updater/index.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ts/updater/index.ts b/ts/updater/index.ts index 036344388..f081b26be 100644 --- a/ts/updater/index.ts +++ b/ts/updater/index.ts @@ -52,10 +52,14 @@ export function stop() { } function autoUpdateDisabled() { + // We need to ensure that if auto update is not present in the user config then we assume it is on by default + const userSetting = config.get('autoUpdate'); + const autoUpdate = typeof userSetting !== 'boolean' || userSetting; + return ( process.mas || // From Electron: Mac App Store build !getFromConfig('updatesEnabled') || // Hard coded config // tslint:disable-next-line: no-backbone-get-set-outside-model - !config.get('autoUpdate') // User setting + !autoUpdate // User setting ); }