Schedule rruleset fix related #13446 (#13611)

Signed-off-by: Kevin Pavon <7450065+KaraokeKev@users.noreply.github.com>
Co-authored-by: Jessica Steurer <70719005+jay-steurer@users.noreply.github.com>
This commit is contained in:
Kevin Pavon
2023-08-16 15:10:31 -04:00
committed by GitHub
parent bb1c155bc9
commit b8ec7c4072
2 changed files with 17 additions and 1 deletions

View File

@@ -214,7 +214,7 @@ class LookupModule(LookupBase):
if not isinstance(rule[field_name], list):
rule[field_name] = rule[field_name].split(',')
for value in rule[field_name]:
value = value.strip()
value = value.strip().lower()
if value not in valid_list:
raise AnsibleError('In rule {0} {1} must only contain values in {2}'.format(rule_number, field_name, ', '.join(valid_list.keys())))
return_values.append(valid_list[value])