Skip to content

Commit

Permalink
Merge pull request #20 from ermetic-research/bugfix/clean-flag-behavior
Browse files Browse the repository at this point in the history
- Fixed bug: clean with filter flags cleaned all scenarios
  • Loading branch information
igofman authored Feb 18, 2024
2 parents e5e568f + 72df031 commit f4f06c7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/commands/clean.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ var CleanCommand = &cli.Command{
moduleTable := c.Context.Value("CNAPPgoatModuleTable").(table.Writer)
engine := c.Context.Value("CNAPPgoatEngine").(*cnappgoat.Engine)
reg := c.Context.Value("CNAPPgoatModuleRegistry").(*cnappgoat.Registry)
if c.Args().Len() == 0 {
if c.Args().Len() == 0 && c.String("module") == "" && c.String("platform") == "" && c.String("state") == "" {
if err := engine.CleanAll(c.Context, c.Bool("force")); err != nil {
return err
}
Expand Down

0 comments on commit f4f06c7

Please sign in to comment.