mirror of
https://github.com/spf13/cobra
synced 2024-11-24 14:47:12 +00:00
fix typos (#1274)
This commit is contained in:
parent
39b5a91b20
commit
7df62f7668
1 changed files with 2 additions and 2 deletions
|
@ -964,13 +964,13 @@ func (c *Command) ExecuteC() (cmd *Command, err error) {
|
|||
return cmd, nil
|
||||
}
|
||||
|
||||
// If root command has SilentErrors flagged,
|
||||
// If root command has SilenceErrors flagged,
|
||||
// all subcommands should respect it
|
||||
if !cmd.SilenceErrors && !c.SilenceErrors {
|
||||
c.PrintErrln("Error:", err.Error())
|
||||
}
|
||||
|
||||
// If root command has SilentUsage flagged,
|
||||
// If root command has SilenceUsage flagged,
|
||||
// all subcommands should respect it
|
||||
if !cmd.SilenceUsage && !c.SilenceUsage {
|
||||
c.Println(cmd.UsageString())
|
||||
|
|
Loading…
Reference in a new issue