mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
check validation with no apps client in kubectl util factory
This commit is contained in:
parent
0da589fa9c
commit
254189a5f2
@ -1080,7 +1080,7 @@ func (c *clientSwaggerSchema) ValidateBytes(data []byte) error {
|
||||
}
|
||||
if gvk.Group == apps.GroupName {
|
||||
if c.c.AppsClient == nil {
|
||||
return errors.New("unable to validate: no autoscaling client")
|
||||
return errors.New("unable to validate: no apps client")
|
||||
}
|
||||
return getSchemaAndValidate(c.c.AppsClient.RESTClient, data, "apis/", gvk.GroupVersion().String(), c.cacheDir, c)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user