Skip to content

Commit f57822b

Browse files
committed
fix(desktop): make committed relaunch non-vetoable
1 parent 60953d2 commit f57822b

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

apps/desktop/src/main/index.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -589,7 +589,7 @@ function main(): void {
589589
logger.error('Quit cancelled because account teardown did not finish safely')
590590
return
591591
}
592-
if (!prepareAccountDataTeardownForQuit()) {
592+
if (!mandatoryRelaunchPending && !prepareAccountDataTeardownForQuit()) {
593593
logger.error('Quit cancelled because account-data recovery could not be persisted')
594594
return
595595
}
@@ -603,7 +603,13 @@ function main(): void {
603603
})
604604
return
605605
}
606-
if (!prepareAccountDataTeardownForQuit()) {
606+
/**
607+
* A mandatory relaunch is requested only after the server-switch transaction
608+
* has cleared deployment-scoped capabilities and committed the replacement
609+
* origin. The ordinary quit guard must not strand that committed process on
610+
* its old partition; any retained marker is startup retry metadata.
611+
*/
612+
if (!mandatoryRelaunchPending && !prepareAccountDataTeardownForQuit()) {
607613
event.preventDefault()
608614
logger.error('Quit cancelled because account-data recovery could not be persisted')
609615
return

0 commit comments

Comments
 (0)