Skip to content

Commit

Permalink
Fix Latest Bug
Browse files Browse the repository at this point in the history
  • Loading branch information
rossedman committed Sep 28, 2021
1 parent 910b504 commit 0202f26
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions cmd/check_versions.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,22 @@ var getVersionsCmd = &cobra.Command{
// find the matching service
req, err := getRequiredVersion(versions, kubeVersion, s.Name)
if err != nil {
return err
return fmt.Errorf("failed to get required version for %s: %s", s.Name, err)
}
if req == "unknown" {
continue
}

if s.Version == "latest" {
t.Rows = append(t.Rows, metav1.TableRow{
Cells: []interface{}{s.Name, false, s.Version, req},
})
continue
}

o, err := isOutOfDate(req, s.Version)
if err != nil {
return err
return fmt.Errorf("failed to calculate out of date for %s: %s", s.Name, err)
}

t.Rows = append(t.Rows, metav1.TableRow{
Expand Down

0 comments on commit 0202f26

Please sign in to comment.