Set destination in GenericFlag apply function

The function was missing destination configuration.
main
Jakub Nowakowski 2 years ago committed by Dan Buch
parent c5057d195e
commit 01bdec784f
Signed by: meatballhat
GPG Key ID: A12F782281063434

@ -34,6 +34,10 @@ func (f *GenericFlag) Apply(set *flag.FlagSet) error {
}
for _, name := range f.Names() {
if f.Destination != nil {
set.Var(f.Destination, name, f.Usage)
continue
}
set.Var(f.Value, name, f.Usage)
}

Loading…
Cancel
Save