fix: correct issue where all flags were not shown if an invalid flag was specified

This commit is contained in:
Jose Diaz-Gonzalez
2021-01-07 01:34:05 -05:00
parent 666bb9dfee
commit d70a9be97e
8 changed files with 56 additions and 20 deletions

View File

@@ -15,10 +15,15 @@ func ReportSingleApp(appName, infoFlag string) error {
"--logs-global-vector-sink": reportGlobalVectorSink,
}
flagKeys := []string{}
for flagKey := range flags {
flagKeys = append(flagKeys, flagKey)
}
trimPrefix := false
uppercaseFirstCharacter := true
infoFlags := common.CollectReport(appName, infoFlag, flags)
return common.ReportSingleApp("logs", appName, infoFlag, infoFlags, trimPrefix, uppercaseFirstCharacter)
return common.ReportSingleApp("logs", appName, infoFlag, infoFlags, flagKeys, trimPrefix, uppercaseFirstCharacter)
}
func reportVectorSink(appName string) string {