mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-28 22:17:14 +00:00
small cleanup on pkg/config
This commit is contained in:
parent
f24ea5ce59
commit
d4c37e352e
@ -78,7 +78,8 @@ func CreateObject(client *client.RESTClient, mapping *meta.RESTMapping, obj runt
|
||||
// TODO: This should be using RESTHelper
|
||||
err = client.Post().Path(mapping.Resource).Namespace(namespace).Body(obj).Do().Error()
|
||||
if err != nil {
|
||||
return &errs.ValidationError{errs.ValidationErrorTypeInvalid, name, err}
|
||||
e := errs.NewFieldInvalid(name, err)
|
||||
return &e
|
||||
}
|
||||
|
||||
return nil
|
||||
|
Loading…
Reference in New Issue
Block a user