mirror of
https://github.com/Zagrios/bs-manager.git
synced 2026-07-03 14:08:25 +02:00
move Update "haveBeenUpdated" when update is available
This commit is contained in:
@@ -13,7 +13,10 @@ ipcMain.on("download-update", async (event, request: IpcRequest<void>) => {
|
||||
|
||||
updaterService
|
||||
.downloadUpdate()
|
||||
.then(res => utilsService.ipcSend(request.responceChannel, { success: res }))
|
||||
.then(res => {
|
||||
utilsService.ipcSend(request.responceChannel, { success: res });
|
||||
updaterService.setHaveBeenUpdated(true);
|
||||
})
|
||||
.catch(() => utilsService.ipcSend(request.responceChannel, { success: false }));
|
||||
});
|
||||
|
||||
|
||||
@@ -39,7 +39,6 @@ export class AutoUpdaterService {
|
||||
if (!info?.updateInfo) {
|
||||
return false;
|
||||
}
|
||||
this.setHaveBeenUpdated(true);
|
||||
return gt(info.updateInfo.version, autoUpdater.currentVersion.version);
|
||||
})();
|
||||
resolve(needUpdate);
|
||||
|
||||
Reference in New Issue
Block a user