mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-12 20:18:41 -09:00
don't prevent app quit
This commit is contained in:
parent
8f2acf43e6
commit
0725a5fc0a
1 changed files with 4 additions and 10 deletions
|
|
@ -57,17 +57,11 @@ const _watch = () => {
|
|||
console.error('error watching config', error);
|
||||
});
|
||||
|
||||
app.on('before-quit', (e) => {
|
||||
app.on('before-quit', () => {
|
||||
if (Object.keys(_watcher.getWatched()).length > 0) {
|
||||
e.preventDefault();
|
||||
_watcher
|
||||
.close()
|
||||
.catch((err) => {
|
||||
console.warn(err);
|
||||
})
|
||||
.finally(() => {
|
||||
app.quit();
|
||||
});
|
||||
_watcher.close().catch((err) => {
|
||||
console.warn(err);
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue