mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-14 21:53:52 +00:00
@@ -119,11 +119,6 @@ func CheckErr(err error) {
|
||||
checkErr(err, fatalErrHandler)
|
||||
}
|
||||
|
||||
// checkErrWithPrefix works like CheckErr, but adds a caller-defined prefix to non-nil errors
|
||||
func checkErrWithPrefix(prefix string, err error) {
|
||||
checkErr(err, fatalErrHandler)
|
||||
}
|
||||
|
||||
// checkErr formats a given error as a string and calls the passed handleErr
|
||||
// func with that string and an kubectl exit code.
|
||||
func checkErr(err error, handleErr func(string, int)) {
|
||||
@@ -595,7 +590,7 @@ func ChangeResourcePatch(info *resource.Info, changeCause string) ([]byte, types
|
||||
}
|
||||
}
|
||||
|
||||
// containsChangeCause checks if input resource info contains change-cause annotation.
|
||||
// ContainsChangeCause checks if input resource info contains change-cause annotation.
|
||||
func ContainsChangeCause(info *resource.Info) bool {
|
||||
annotations, err := info.Mapping.MetadataAccessor.Annotations(info.Object)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user