From c17a56cd672de6f1bbfb5abc6d06ee0bdebb7b3f Mon Sep 17 00:00:00 2001 From: Quentin Decaunes Date: Mon, 3 Jun 2019 16:21:37 +0200 Subject: [PATCH] Ensure shortcut creation on first launch. --- main.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/main.js b/main.js index a563723..b34cf84 100644 --- a/main.js +++ b/main.js @@ -122,7 +122,18 @@ if (!setupEvents.handleSquirrelEvent()) { ); } - + if (!old_version) { + settings.set('settings', + Object.assign( + {}, + settings.set('settings'), + { + last_used_version: require('./package.json').version, + first_launch: true, + } + ) + ); + } // Keep a global reference of the window object, if you don't, the window will // be closed automatically when the JavaScript object is garbage collected. let mainWindow