From 2eb878bebef35e70bb0b15cc6e7c9e0af1bd7395 Mon Sep 17 00:00:00 2001 From: Guillermo Rauch Date: Fri, 8 Jul 2016 05:48:42 -0700 Subject: [PATCH] auto-updater: less intrusive error handling --- auto-updater.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/auto-updater.js b/auto-updater.js index 142a0999..c0214375 100644 --- a/auto-updater.js +++ b/auto-updater.js @@ -1,5 +1,6 @@ -const { autoUpdater, dialog } = require('electron'); +const { autoUpdater } = require('electron'); const { version } = require('./package'); +const notify = require('./notify'); const ms = require('ms'); const FEED_URL = 'https://hyperterm-updates.now.sh/update/osx'; @@ -7,11 +8,7 @@ let isInit = false; function init () { autoUpdater.on('error', (err, msg) => { - dialog.showMessageBox({ - title: 'title', - message: 'Auto updater error: ' + msg + ' (' + err.stack + ')', - buttons: ['Ok'] - }); + notify('Error fetching updates', msg + ' (' + err.stack + ')'); }); autoUpdater.setFeedURL(`${FEED_URL}/${version}`);