Merge remote-tracking branch 'origin/main' into michaeljs1990-add-flag-category-support

This commit is contained in:
2022-05-22 11:06:38 -04:00
24 changed files with 103 additions and 69 deletions

View File

@@ -44,7 +44,7 @@ func (f *StringFlag) GetEnvVars() []string {
// Apply populates the flag given the flag set and environment
func (f *StringFlag) Apply(set *flag.FlagSet) error {
if val, ok := flagFromEnvOrFile(f.EnvVars, f.FilePath); ok {
if val, _, found := flagFromEnvOrFile(f.EnvVars, f.FilePath); found {
f.Value = val
f.HasBeenSet = true
}