mirror of
https://github.com/aquasecurity/trivy.git
synced 2025-12-20 14:22:50 -08:00
fix: persistent flag option typo (#9374)
This commit is contained in:
@@ -317,7 +317,7 @@ func (f *Flag[T]) Bind(cmd *cobra.Command) error {
|
||||
|
||||
// Bind CLI flags
|
||||
flag := cmd.Flags().Lookup(f.Name)
|
||||
if f == nil {
|
||||
if flag == nil {
|
||||
// Lookup local persistent flags
|
||||
flag = cmd.PersistentFlags().Lookup(f.Name)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user