Update cmd/minikube/cmd/config/profile_list.go

spowelljr: set status to as.String() just once

Co-authored-by: Steven Powell <44844360+spowelljr@users.noreply.github.com>
pull/17909/head
Predrag Rogic 2024-01-31 01:09:54 +00:00 committed by GitHub
parent 9d5dfafe7c
commit 2ec34729ad
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 2 deletions

View File

@ -166,13 +166,12 @@ func profileStatus(p *config.Profile, api libmachine.API) string {
klog.Warningf("error loading profile (will continue): apiserver status for %s: %v", machineName, err)
continue
}
status = as.String()
if as != state.Running {
klog.Warningf("error loading profile (will continue): apiserver %s is not running: %q", machineName, hs)
status = as.String()
continue
}
status = state.Running.String()
healthyCPs++
}