fix(db_query): handle null in fields list
This commit is contained in:
parent
d04188283c
commit
43fe6bd152
1 changed files with 3 additions and 0 deletions
|
|
@ -172,6 +172,9 @@ class DatabaseQuery(object):
|
|||
except ValueError:
|
||||
self.fields = [f.strip() for f in self.fields.split(",")]
|
||||
|
||||
# remove empty strings / nulls in fields
|
||||
self.fields = [f for f in self.fields if f]
|
||||
|
||||
for filter_name in ["filters", "or_filters"]:
|
||||
filters = getattr(self, filter_name)
|
||||
if isinstance(filters, string_types):
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue