Skip to content

Commit

Permalink
Fix mixing of Rule class and rule XML element
Browse files Browse the repository at this point in the history
  • Loading branch information
Honny1 committed Sep 13, 2022
1 parent a6e75b7 commit 223f566
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions openscap_report/scap_results_parser/parsers/rule_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,8 +174,8 @@ def _insert_rules_results(self, rules):

def get_rules(self):
rules = {}
for rule in self.root.findall(".//xccdf:Rule", NAMESPACES):
rule = self.process_rule(rule)
for rule_el in self.root.findall(".//xccdf:Rule", NAMESPACES):
rule = self.process_rule(rule_el)
rules[rule.rule_id] = rule
self._insert_rules_results(rules)
return rules

0 comments on commit 223f566

Please sign in to comment.