fix bugs that break processing when printing errors occur in kubectl

This commit is contained in:
WanLinghao
2018-05-24 09:48:24 +08:00
parent b5cd7d81bd
commit b020a4ba8c
7 changed files with 21 additions and 13 deletions

View File

@@ -276,7 +276,7 @@ func (o *SetImageOptions) Run() error {
if o.Local || o.DryRun {
if err := o.PrintObj(info.Object, o.Out); err != nil {
return err
allErrs = append(allErrs, err)
}
continue
}
@@ -289,7 +289,7 @@ func (o *SetImageOptions) Run() error {
}
if err := o.PrintObj(actual, o.Out); err != nil {
return err
allErrs = append(allErrs, err)
}
}
return utilerrors.NewAggregate(allErrs)