quote the flag name

main
Lynn Cyrin 5 years ago
parent 6a2ae78373
commit f6777bf4bf
No known key found for this signature in database
GPG Key ID: EE9CCB427DFEC897

@ -305,7 +305,7 @@ func checkRequiredFlags(flags []Flag, set *flag.FlagSet) error {
if rf.IsRequired() { if rf.IsRequired() {
key := strings.Split(f.GetName(), ",")[0] key := strings.Split(f.GetName(), ",")[0]
if !visited[key] { if !visited[key] {
return fmt.Errorf("Required flag %s not set", f.GetName()) return fmt.Errorf("Required flag %q not set", f.GetName())
} }
} }
} }

Loading…
Cancel
Save