diff --git a/src/browser/squirrel-update.coffee b/src/browser/squirrel-update.coffee index 4e68ddd27..9a80fd141 100644 --- a/src/browser/squirrel-update.coffee +++ b/src/browser/squirrel-update.coffee @@ -66,6 +66,8 @@ uninstallContextMenu = (callback) -> updatePath = (callback) -> getPath = (callback) -> spawnReg ['query', environmentKeyPath, '/v', 'Path'], (error, stdout) -> + return callback(error) if error? + lines = stdout.split(/[\r\n]+/).filter (line) -> line segments = lines[lines.length - 1]?.split(' ') if segments[1] is 'Path' and segments.length >= 3