Skip to content

Commit 0fbecd2

Browse files
committed
Validation filler
1 parent 2e7181c commit 0fbecd2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

caltechdata_api/decustomize_schema.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,9 @@ def decustomize_schema(json_record,pass_emails=False,pass_media=False):
133133
if isinstance(json_record['publicationDate'],str):
134134
year = json_record['publicationDate'].split('-')[0]
135135
json_record['publicationYear'] = year
136+
else:
137+
#Junk validation filler
138+
json_record['publicationYear'] = '0000'
136139

137140
#If "Submitted' date type was not manually set in metadata
138141
#Or 'Issued was not manually set

0 commit comments

Comments
 (0)