don't use set for value conversion

This commit is contained in:
Jakub Trllo 2025-11-05 16:12:17 +01:00
parent b1422b7fb4
commit 64f511a43b

View file

@ -604,7 +604,11 @@ class EnumDef(AbstractAttrDef):
if value is None:
return copy.deepcopy(self.default)
return list(self._item_values.intersection(value))
return [
v
for v in value
if v in self._item_values
]
def is_value_valid(self, value: Any) -> bool:
"""Check if item is available in possible values."""