From 2e156b8990a1e72cfb231eadafe76e4e60c096ea Mon Sep 17 00:00:00 2001
From: Brendan Allan <14191578+Brendonovich@users.noreply.github.com>
Date: Fri, 24 Apr 2026 13:27:36 +0800
Subject: fix(desktop): avoid relaunching without installing updates (#23806)

---
 packages/app/src/pages/error.tsx | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

(limited to 'packages/app/src/pages/error.tsx')

diff --git a/packages/app/src/pages/error.tsx b/packages/app/src/pages/error.tsx
index 11284b3d2..ba0045ec9 100644
--- a/packages/app/src/pages/error.tsx
+++ b/packages/app/src/pages/error.tsx
@@ -244,10 +244,9 @@ export const ErrorPage: Component<ErrorPageProps> = (props) => {
   }
 
   async function installUpdate() {
-    if (!platform.update || !platform.restart) return
+    if (!platform.updateAndRestart) return
     await platform
-      .update()
-      .then(() => platform.restart!())
+      .updateAndRestart()
       .then(() => setStore("actionError", undefined))
       .catch((err) => {
         setStore("actionError", formatError(err, language.t))
-- 
cgit v1.2.3

