fixing bug to allow all measures when no inclusions or exclusions are specified

This commit is contained in:
Khalim Conn-Kowlessar 2024-09-18 13:32:42 +01:00
parent ef6aad6425
commit 7d907ce8c0

View file

@ -79,7 +79,9 @@ class Recommendations:
inclusions_full = [MEASURE_MAP[x] if x in MEASURE_MAP else x for x in self.inclusions]
exclusions_full = [MEASURE_MAP[x] if x in MEASURE_MAP else x for x in self.exclusions]
if inclusions_full and exclusions_full:
# If inclusions and exclusions are empty, it means that nothing was specified, so we allow
# all recommendation types
if not inclusions_full and not exclusions_full:
# All typical measures
return self.all_specific_measures