From 5f2face7178ac2a43f35ec4db89b44db680ae9a3 Mon Sep 17 00:00:00 2001 From: ciregenz Date: Fri, 12 Jun 2026 21:29:26 -0700 Subject: [PATCH] [eric] updater: render the update banner version-less when unknown, kills 'OpenSwarm null' (Windows Squirrel + mid-download reload) --- frontend/src/app/components/Layout/AppShell.tsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/frontend/src/app/components/Layout/AppShell.tsx b/frontend/src/app/components/Layout/AppShell.tsx index 60f0d8c7..80e9ad71 100644 --- a/frontend/src/app/components/Layout/AppShell.tsx +++ b/frontend/src/app/components/Layout/AppShell.tsx @@ -117,6 +117,8 @@ const AppShell: React.FC = () => { const availableVersion = useAppSelector((state) => state.update.availableVersion); const downloadPercent = useAppSelector((state) => state.update.downloadPercent); const installing = useAppSelector((state) => state.update.installing); + // Windows' Squirrel never reports a version, and a mid-download cache-clear reload wipes it, so render the name version-less instead of "OpenSwarm null". + const verSuffix = availableVersion ? ` ${availableVersion}` : ''; const [dismissedVersion, setDismissedVersion] = useState(() => { try { return localStorage.getItem(UPDATE_DISMISS_KEY); } catch { return null; } @@ -551,9 +553,9 @@ const AppShell: React.FC = () => { > - {updateStatus === 'available' && `OpenSwarm ${availableVersion} is available`} - {updateStatus === 'downloading' && `Downloading OpenSwarm ${availableVersion}…`} - {updateStatus === 'downloaded' && `OpenSwarm ${availableVersion} will install when you quit`} + {updateStatus === 'available' && `OpenSwarm${verSuffix} is available`} + {updateStatus === 'downloading' && `Downloading OpenSwarm${verSuffix}…`} + {updateStatus === 'downloaded' && `OpenSwarm${verSuffix} will install when you quit`} {updateStatus === 'downloading' && ( { '& .MuiAlert-icon': { color: c.accent.primary }, }} > - {updateStatus === 'available' && `OpenSwarm ${availableVersion} is available`} - {updateStatus === 'downloaded' && `OpenSwarm ${availableVersion} downloaded; restart to update`} + {updateStatus === 'available' && `OpenSwarm${verSuffix} is available`} + {updateStatus === 'downloaded' && `OpenSwarm${verSuffix} downloaded; restart to update`}