summaryrefslogtreecommitdiffstats
path: root/core/views/scans.py
diff options
context:
space:
mode:
authorPhilip Sargent <philip.sargent@klebos.com>2022-09-20 22:52:31 +0300
committerPhilip Sargent <philip.sargent@klebos.com>2022-09-20 22:52:31 +0300
commit71bd07e70e542df553c595096dede77ea9569052 (patch)
treeda4df221a9f8fe908ba94bf406c4fce6e63ef1ec /core/views/scans.py
parent94b49adc4ed961807ca32b726ccbf300f129e49c (diff)
downloadtroggle-71bd07e70e542df553c595096dede77ea9569052.tar.gz
troggle-71bd07e70e542df553c595096dede77ea9569052.tar.bz2
troggle-71bd07e70e542df553c595096dede77ea9569052.zip
Handling and fixing bad dates in JSON input
Diffstat (limited to 'core/views/scans.py')
-rw-r--r--core/views/scans.py15
1 files changed, 9 insertions, 6 deletions
diff --git a/core/views/scans.py b/core/views/scans.py
index 80b334d..d3fd517 100644
--- a/core/views/scans.py
+++ b/core/views/scans.py
@@ -82,12 +82,15 @@ def fillblankpeople(w):
# this isn't working..? why? Because it needs a *ref and an import
wp = w.people()
w.persons = wp
- if len(wp) == 1:
- # print(f' - {wp=}')
- nobody = wp[0].lower()
- if nobody == 'unknown' or nobody == 'nobody' or nobody == ' ' or nobody == '':
- print(f' - {wp=} {nobody=}')
- populatewallet(w)
+ if not wp:
+ populatewallet(w)
+ else:
+ if len(wp) == 1:
+ # print(f' - {wp=}')
+ nobody = wp[0].lower()
+ if nobody == 'unknown' or nobody == 'nobody' or nobody == ' ' or nobody == '':
+ print(f' - {wp=} {nobody=}')
+ populatewallet(w)
def fillblankothers(w):
earliest = datetime.datetime.now().date()