Skip to content

Commit 2dbdfd9

Browse files
authored
fix: Don't auto-install updates when user quits the app (#1255)
1 parent 53c30a7 commit 2dbdfd9

File tree

1 file changed

+0
-15
lines changed

1 file changed

+0
-15
lines changed

apps/code/src/main/index.ts

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -124,21 +124,6 @@ app.on("before-quit", async (event) => {
124124

125125
event.preventDefault();
126126

127-
// If an update is downloaded, install it instead of doing a normal shutdown.
128-
// installUpdate() handles its own lightweight cleanup and quitAndInstall.
129-
try {
130-
const updatesService = container.get<UpdatesService>(
131-
MAIN_TOKENS.UpdatesService,
132-
);
133-
if (updatesService.hasUpdateReady) {
134-
log.info("Update ready, installing on quit");
135-
const { installed } = await updatesService.installUpdate();
136-
if (installed) return;
137-
}
138-
} catch {
139-
// Updates service not available, fall through to normal shutdown
140-
}
141-
142127
await lifecycleService.gracefulExit();
143128
});
144129

0 commit comments

Comments
 (0)