Fix initial sync complete on empty service list

This commit is contained in:
Viktor Liu
2026-02-12 15:10:53 +08:00
parent 5d606d909d
commit 38db42e7d6
10 changed files with 693 additions and 267 deletions

View File

@@ -648,7 +648,8 @@ func (h *Handler) handleHealth(w http.ResponseWriter, r *http.Request, wantJSON
allHealthy, clientHealth := h.health.CheckClientsConnected(r.Context())
status := "ok"
if !ready || !allHealthy {
// No clients is not a health issue; only degrade when actual clients are unhealthy
if !ready || (!allHealthy && len(clientHealth) > 0) {
status = "degraded"
}