Fixed incorrect IsEmpty() check that would return true if exactly one of HasIncludes() or HasExcludes() returned true

This commit is contained in:
Seednode 2022-12-20 17:12:37 -06:00
parent 5ef1d19780
commit cfbffb6dab
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ import (
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
var Version = "0.26.2" var Version = "0.27.0"
func init() { func init() {
rootCmd.AddCommand(versionCmd) rootCmd.AddCommand(versionCmd)

View File

@ -39,7 +39,7 @@ type Filters struct {
} }
func (f *Filters) IsEmpty() bool { func (f *Filters) IsEmpty() bool {
return !(f.HasIncludes() && f.HasExcludes()) return !(f.HasIncludes() || f.HasExcludes())
} }
func (f *Filters) HasIncludes() bool { func (f *Filters) HasIncludes() bool {