mirror of
https://github.com/ZwareBear/awx.git
synced 2026-04-22 07:51:52 -05:00
Merge pull request #1666 from wwitzel3/issue-1652
do not allow requests with empty values in __in values
This commit is contained in:
@@ -132,6 +132,8 @@ class FieldLookupBackend(BaseFilterBackend):
|
||||
elif new_lookup.endswith('__in'):
|
||||
items = []
|
||||
for item in value.split(','):
|
||||
if not item:
|
||||
raise ValueError('cannot provide empty value for __in')
|
||||
items.append(self.value_to_python_for_field(field, item))
|
||||
value = items
|
||||
elif new_lookup.endswith('__regex') or new_lookup.endswith('__iregex'):
|
||||
|
||||
Reference in New Issue
Block a user