Remove unnecessary code

This commit is contained in:
xichengliudui 2018-11-08 12:40:13 -05:00
parent 5826e4f361
commit 9979549050
3 changed files with 3 additions and 3 deletions

View File

@ -36,7 +36,7 @@ func checkParse(t *testing.T, s string, expect map[string]string, shouldErr bool
if err != nil {
if shouldErr {
return
}
}
t.Errorf(err.Error())
}

View File

@ -165,7 +165,7 @@ func RunReplace(f *util.Factory, cmd *cobra.Command, out io.Writer, c *replaceOp
if err != nil {
if errors.IsNotFound(err) {
return fmt.Errorf("cluster %q not found", clusterName)
}
}
return fmt.Errorf("error fetching cluster %q: %v", clusterName, err)
}
// check if the instancegroup exists already

View File

@ -221,7 +221,7 @@ func (c *RootCmd) ProcessArgs(args []string) error {
if len(args) == 1 {
return fmt.Errorf("Cannot specify cluster via --name and positional argument")
}
}
return fmt.Errorf("expected a single <clustername> to be passed as an argument")
}