mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-31 03:45:17 +00:00
Fix bug in event creation for failed policies (#2652)
Signed-off-by: yulianedyalkova <julianedialkova@gmail.com>
This commit is contained in:
parent
4eab46fb7d
commit
40d30df726
1 changed files with 1 additions and 1 deletions
|
@ -208,7 +208,7 @@ func generateFailEventsPerEr(log logr.Logger, er *response.EngineResponse) []eve
|
|||
logger.V(4).Info("reporting fail results for policy")
|
||||
|
||||
for _, rule := range er.PolicyResponse.Rules {
|
||||
if rule.Status != response.RuleStatusPass {
|
||||
if rule.Status == response.RuleStatusPass {
|
||||
continue
|
||||
}
|
||||
// generate event on resource for each failed rule
|
||||
|
|
Loading…
Add table
Reference in a new issue