Addressed PR comments.

This commit is contained in:
Julio-Oliveira-Encora 2024-05-29 14:50:14 -03:00
parent 270bd53301
commit e94b2f39d0

View File

@ -135,7 +135,7 @@ class ConditionSet:
def __init__(self, ruleset): def __init__(self, ruleset):
if type(ruleset) is not dict: if type(ruleset) is not dict:
raise ValueError(_("Ruleset must be a dictionary, not {ruleset}.").format(ruleset=type(ruleset))) raise ValueError(_("Ruleset must be a dictionary, not {ruleset}.").format(ruleset=type(ruleset)))
print(len(ruleset))
if len(ruleset) == 1: if len(ruleset) == 1:
self.logic = (list(ruleset.keys())[0]).lower() self.logic = (list(ruleset.keys())[0]).lower()
if self.logic not in (AND, OR): if self.logic not in (AND, OR):