Skip to content
Permalink
Browse files

Update cmd.go

Fixed redundant usage of "flags.SetNormalizeFunc"
  • Loading branch information...
bullrox committed Jun 1, 2019
1 parent 21c9c7a commit 76041399cf8d904ae720f2a8f5f4fac74b2e34e4
Showing with 3 additions and 4 deletions.
  1. +3 −4 pkg/kubectl/cmd/cmd.go
@@ -431,11 +431,10 @@ func NewKubectlCommand(in io.Reader, out, err io.Writer) *cobra.Command {
}

flags := cmds.PersistentFlags()
flags.SetNormalizeFunc(cliflag.WarnWordSepNormalizeFunc) // Warn for "_" flags


// Normalize all flags that are coming from other packages or pre-configurations
// a.k.a. change all "_" to "-". e.g. glog package
flags.SetNormalizeFunc(cliflag.WordSepNormalizeFunc)
// a.k.a. change all "_" to "-". e.g. glog package. Warn for "_" flags.
flags.SetNormalizeFunc(cliflag.WarnWordSepNormalizeFunc)

addProfilingFlags(flags)

0 comments on commit 7604139

Please sign in to comment.
You can’t perform that action at this time.