set birth_date to 1970-01-01 if missing.
because we use it to track underageness.
This commit is contained in:
parent
266c999be3
commit
96ee3032d4
@ -175,6 +175,8 @@ def import_member(member_data):
|
||||
|
||||
for key in ['birth_date', 'nick', 'phone_number']:
|
||||
value = member_data.get(f'profile__{key}')
|
||||
if not value and key == 'birth_date':
|
||||
value = '1970-1-1'
|
||||
if value:
|
||||
setattr(member.profile_profile, key, value)
|
||||
member.profile_profile.save()
|
||||
|
Loading…
Reference in New Issue
Block a user