construct values in queryset instead of serializer methods

This commit is contained in:
smilerz
2022-01-11 07:24:59 -06:00
parent 30683fe455
commit f7cb067b52
5 changed files with 82 additions and 40 deletions

View File

@ -7,7 +7,7 @@ class Round(Func):
def str2bool(v):
if type(v) == bool:
if type(v) == bool or v is None:
return v
else:
return v.lower() in ("yes", "true", "1")