Skip to content

Commit

Permalink
fix: node health error
Browse files Browse the repository at this point in the history
  • Loading branch information
adityathebe authored and moshloop committed Aug 8, 2024
1 parent c786877 commit 155055b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions pkg/health/health_node.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package health

import (
"errors"
"fmt"

v1 "k8s.io/api/core/v1"
Expand Down Expand Up @@ -43,5 +42,9 @@ func getNodeHealth(obj *unstructured.Unstructured) (*HealthStatus, error) {
}
}

return nil, errors.New("no conditions matched for node status")
return &HealthStatus{
Status: HealthStatusUnknown,
Health: HealthUnknown,
Message: "no conditions matched for node status",
}, nil
}

0 comments on commit 155055b

Please sign in to comment.