From 88f31fe9a268135369a2e33f7722ece10e37fc49 Mon Sep 17 00:00:00 2001 From: Eric Leblond Date: Mon, 12 Mar 2018 14:33:57 +0100 Subject: [PATCH] rules: fix is_active function --- rules/models.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/rules/models.py b/rules/models.py index f933f18f5..10a718129 100644 --- a/rules/models.py +++ b/rules/models.py @@ -1391,6 +1391,8 @@ def parse_flowbits(self, source, flowbits, addition = False): flowbits['added']['through_set'].append(through_elt) def is_active(self, ruleset): + SUPPRESSED = Transformation.SUPPRESSED + S_SUPPRESSED = Transformation.S_SUPPRESSED if self.state and self.category in ruleset.categories.all() and self not in ruleset.get_transformed_rules(key=SUPPRESSED, value=S_SUPPRESSED): return True return False