mirror of
https://github.com/kubernetes/kubernetes.git
synced 2026-05-28 04:04:39 -04:00
Use IsListType instead of checking ItemPtr in resourcebuilder
This commit is contained in:
parent
b799e8cd3a
commit
a97635e643
1 changed files with 1 additions and 1 deletions
|
|
@ -133,7 +133,7 @@ func (r *Result) Object() (runtime.Object, error) {
|
|||
return objects[0], nil
|
||||
}
|
||||
// if the item is a list already, don't create another list
|
||||
if _, err := runtime.GetItemsPtr(objects[0]); err == nil {
|
||||
if runtime.IsListType(objects[0]) {
|
||||
return objects[0], nil
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue