Skip to content

Commit

Permalink
default result.severity to info when formatting string
Browse files Browse the repository at this point in the history
  • Loading branch information
Mengqi Yu committed Nov 19, 2021
1 parent 820ed31 commit f9e1628
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion kyaml/fn/framework/result.go
Expand Up @@ -64,7 +64,12 @@ func (i Result) String() string {
}
}
formatString := "[%s]"
list := []interface{}{i.Severity}
severity := i.Severity
// We default Severity to Info when converting a result to a message.
if i.Severity == "" {
severity = Info
}
list := []interface{}{severity}
if len(idStringList) > 0 {
formatString += " %s"
list = append(list, strings.Join(idStringList, "/"))
Expand Down

0 comments on commit f9e1628

Please sign in to comment.