fix(ota): set updating to false when no updates are available (#996)

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Aveline 2025-11-21 01:44:50 +01:00 committed by GitHub
parent 9c4a9e144f
commit ae9cf78f1c
1 changed files with 7 additions and 0 deletions

View File

@ -228,6 +228,13 @@ func (s *State) doUpdate(ctx context.Context, params UpdateParams) error {
s.triggerComponentUpdateState("system", systemUpdate) s.triggerComponentUpdateState("system", systemUpdate)
} }
if !appUpdate.pending && !systemUpdate.pending {
scopedLogger.Info().Msg("No updates available")
s.updating = false
s.triggerStateUpdate()
return nil
}
scopedLogger.Trace().Bool("pending", appUpdate.pending).Msg("Checking for app update") scopedLogger.Trace().Bool("pending", appUpdate.pending).Msg("Checking for app update")
if appUpdate.pending { if appUpdate.pending {