Introduce Electron version (follow-up 2) (#3251)
This commit is contained in:
parent
e35c0e0399
commit
5d7b99fd3a
@ -141,9 +141,15 @@ function setupAutoUpdates(window: BrowserWindow) {
|
||||
});
|
||||
}
|
||||
|
||||
autoUpdater.on('error', (error: Error) => window.webContents.send(ElectronEvent.UPDATE_ERROR, error));
|
||||
autoUpdater.on('error', (error: Error) => {
|
||||
if (windows.has(window)) {
|
||||
window.webContents.send(ElectronEvent.UPDATE_ERROR, error);
|
||||
}
|
||||
});
|
||||
autoUpdater.on('update-downloaded', (info: UpdateInfo) => {
|
||||
window.webContents.send(ElectronEvent.UPDATE_DOWNLOADED, info);
|
||||
if (windows.has(window)) {
|
||||
window.webContents.send(ElectronEvent.UPDATE_DOWNLOADED, info);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user