Use IsListType instead of checking ItemPtr in resourcebuilder

This commit is contained in:
Clayton Coleman 2015-03-03 22:18:57 -05:00
parent b799e8cd3a
commit a97635e643

View File

@ -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
}
}