Use None check instead of general falsey for minmax
This commit is contained in:
parent
b69ef8ea00
commit
5ee6062cad
1 changed files with 4 additions and 2 deletions
|
@ -825,14 +825,16 @@ class PDBPhotoMixin:
|
|||
continue
|
||||
|
||||
if any(
|
||||
not fetch[constants.SQL_PHOTO[key]] or fetch[constants.SQL_PHOTO[key]] > value
|
||||
fetch[constants.SQL_PHOTO[key]] is None or
|
||||
fetch[constants.SQL_PHOTO[key]] > value
|
||||
for (key, value) in maximums.items()
|
||||
):
|
||||
#print('Failed maximums')
|
||||
continue
|
||||
|
||||
if any(
|
||||
not fetch[constants.SQL_PHOTO[key]] or fetch[constants.SQL_PHOTO[key]] < value
|
||||
fetch[constants.SQL_PHOTO[key]] is None or
|
||||
fetch[constants.SQL_PHOTO[key]] < value
|
||||
for (key, value) in minimums.items()
|
||||
):
|
||||
#print('Failed minimums')
|
||||
|
|
Loading…
Reference in a new issue