Skip to content

Commit

Permalink
show not exist when disable not-found addon (#241)
Browse files Browse the repository at this point in the history
Signed-off-by: jichenjc <[email protected]>
  • Loading branch information
jichenjc authored Jul 25, 2022
1 parent e4697e3 commit 796024a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/cmd/addon/disable/exec.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,12 @@ func (o *Options) runWithClient(clusterClient clusterclientset.Interface,
if err != nil {
if !errors.IsNotFound(err) {
return err
} else {
fmt.Fprintf(o.Streams.Out, "%s add-on not found in cluster: %s.\n", addon, clusterName)
}
} else {
fmt.Fprintf(o.Streams.Out, "Undeploying %s add-on in managed cluster: %s.\n", addon, clusterName)
}
fmt.Fprintf(o.Streams.Out, "Undeploying %s add-on in managed cluster: %s.\n", addon, clusterName)
}
}

Expand Down

0 comments on commit 796024a

Please sign in to comment.