diff --git a/pydivert/filter.py b/pydivert/filter.py index 8df61d5..afcfe9d 100644 --- a/pydivert/filter.py +++ b/pydivert/filter.py @@ -156,13 +156,7 @@ def logic_and(self, children): for child in children: if not isinstance(child, list) or not child: continue # pragma: no cover - new_result = [] - for existing_rule in result_rules: - for new_rule_part in child: - merged = existing_rule.copy() - merged.update(new_rule_part) - new_result.append(merged) - result_rules = new_result + result_rules = [existing | new for existing in result_rules for new in child] return result_rules def logic_or(self, children):