Browse Source

fix(app): simplify app quit process

Remove redundant code relating to the app close/quit process.
renovate/lint-staged-8.x
Tom Kirkpatrick 6 years ago
parent
commit
dfa09c70f5
No known key found for this signature in database GPG Key ID: 72203A8EC5967EA8
  1. 3
      app/lib/zap/controller.js
  2. 12
      app/main.dev.js

3
app/lib/zap/controller.js

@ -199,9 +199,6 @@ class ZapController {
if (this.neutrino) {
this.neutrino.stop()
}
// Give the grpc connections a chance to be properly closed out.
return new Promise(resolve => setTimeout(resolve, 200))
}
onTerminate() {

12
app/main.dev.js

@ -99,18 +99,6 @@ app.on('ready', () => {
}
})
/**
* Add application event listener:
* - quit app when window is closed
*/
app.on('window-all-closed', () => {
mainLog.debug('app.window-all-closed')
// Respect the OSX convention of having the application in memory even after all windows have been closed
if (process.platform !== 'darwin') {
app.quit()
}
})
/**
* Add application event listener:
* - Stop gRPC and kill lnd process before the app windows are closed and the app quits.

Loading…
Cancel
Save