mirror of
https://github.com/Crosstalk-Solutions/project-nomad.git
synced 2026-03-28 03:29:25 +01:00
fix(UI): clear stale update banner after successful update
After an update completes, the page reloads but the KV store still has updateAvailable=true from the pre-update check. This causes the banner to show "Current 1.30.0-rc.1 → New 1.30.0-rc.1" until the user manually clicks Check Again. Now triggers a version re-check before the post-update reload so the KV store is updated and the banner reflects the correct state. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
456a6d33b1
commit
ee7e1f2366
|
|
@ -258,7 +258,13 @@ export default function SystemUpdatePage(props: { system: Props }) {
|
|||
|
||||
// Check if update is complete or errored
|
||||
if (response.stage === 'complete') {
|
||||
// Give a moment for the new container to fully start
|
||||
// Re-check version so the KV store clears the stale "update available" flag
|
||||
// before we reload, otherwise the banner shows "current → current"
|
||||
try {
|
||||
await api.checkLatestVersion(true)
|
||||
} catch {
|
||||
// Non-critical - page reload will still work
|
||||
}
|
||||
setTimeout(() => {
|
||||
window.location.reload()
|
||||
}, 2000)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user