Merge pull request #101780 from nak3/fix-create-cm

Fix error handling for kubectl create configmap

Kubernetes-commit: 78df56def61cd604d6307fca2536438e9b49f822
This commit is contained in:
Kubernetes Publisher 2021-05-10 16:39:37 -07:00
commit 42bf494e6f
1 changed files with 1 additions and 1 deletions

View File

@ -215,7 +215,7 @@ func (o *ConfigMapOptions) Validate() error {
func (o *ConfigMapOptions) Run() error {
configMap, err := o.createConfigMap()
if err != nil {
return nil
return err
}
if err := util.CreateOrUpdateAnnotation(o.CreateAnnotation, configMap, scheme.DefaultJSONEncoder()); err != nil {
return err