mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 04:06:03 +00:00
Fix nil pointer when validating in kubectl.
This commit is contained in:
parent
f0da47b2dd
commit
8bf104503c
@ -98,6 +98,10 @@ func (s *SwaggerSchema) ValidateObject(obj interface{}, apiVersion, fieldName, t
|
||||
glog.V(2).Infof("couldn't find properties for %s, skipping", key)
|
||||
continue
|
||||
}
|
||||
if details.Type == nil {
|
||||
glog.V(2).Infof("nil details for %s, skipping", key)
|
||||
continue
|
||||
}
|
||||
fieldType := *details.Type
|
||||
if value == nil {
|
||||
glog.V(2).Infof("Skipping nil field: %s", key)
|
||||
|
Loading…
Reference in New Issue
Block a user