1
0
mirror of https://github.com/rancher/norman.git synced 2025-08-01 23:41:24 +00:00

Fix non-updating condition

This commit is contained in:
Darren Shepherd 2018-02-02 23:42:05 -07:00
parent 151aa66e3e
commit d63581239c

View File

@ -223,7 +223,7 @@ func findOrCreateCond(obj interface{}, condName string) reflect.Value {
newCond.FieldByName("Type").SetString(condName)
newCond.FieldByName("Status").SetString("Unknown")
condSlice.Set(reflect.Append(condSlice, newCond))
return newCond
return *findCond(condSlice, condName)
}
func findCond(val reflect.Value, name string) *reflect.Value {