소스 검색

app: use `app.on('before-quit')` to detect app closing

Jeffrey Morgan 1 년 전
부모
커밋
52ea4d4bb2
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      app/src/index.ts

+ 1 - 1
app/src/index.ts

@@ -107,7 +107,7 @@ function server() {
     server()
   })
 
-  process.on('exit', () => {
+  app.on('before-quit', () => {
     proc.off('exit', restart)
     proc.kill()
   })