fix app.dock is undefined caused issue on windows

This commit is contained in:
geekgeekrun
2024-02-24 14:30:49 +08:00
parent 2c549b4d1c
commit 45bf49c1ba
2 changed files with 2 additions and 2 deletions

View File

@@ -9,7 +9,7 @@ export enum DOWNLOAD_ERROR_EXIT_CODE {
}
export const checkAndDownloadDependenciesForInit = async () => {
process.on('disconnect', () => app.exit())
app.dock.hide()
app.dock?.hide()
let pipe: null | net.Socket = null
try {
pipe = new net.Socket({ fd: 3 })

View File

@@ -25,7 +25,7 @@ export const runAutoChat = async () => {
closeBrowserWindow()
app.exit()
})
app.dock.hide()
app.dock?.hide()
let pipe: null | net.Socket = null
try {
pipe = new net.Socket({ fd: 3 })