Skip to content

Commit

Permalink
Clear code after start of use requestSingleInstanceLock
Browse files Browse the repository at this point in the history
The PR removes unnecessary bits
  • Loading branch information
apsavin authored Oct 30, 2018
1 parent 7338156 commit 544846b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ if (process.mas) app.setName('Electron APIs')
let mainWindow = null

function initialize () {
const shouldQuit = makeSingleInstance()
if (shouldQuit) return app.quit()
makeSingleInstance()

loadDemos()

Expand Down Expand Up @@ -73,7 +72,7 @@ function initialize () {
// Returns true if the current version of the app should quit instead of
// launching.
function makeSingleInstance () {
if (process.mas) return false
if (process.mas) return

app.requestSingleInstanceLock()

Expand Down

0 comments on commit 544846b

Please sign in to comment.