Coalesce HarvestUser telephone to null
This commit is contained in:
parent
14f9dfdaa9
commit
63d238d307
|
@ -110,6 +110,15 @@ class HarvestUserImporter(FromHarvest, rattail_harvest_importing.model.HarvestUs
|
|||
def get_host_objects(self):
|
||||
return self.webapi.get_users()['users']
|
||||
|
||||
def normalize_host_object(self, user):
|
||||
data = super(HarvestUserImporter, self).normalize_host_object(user)
|
||||
if data:
|
||||
|
||||
if data['telephone'] == '':
|
||||
data['telephone'] = None
|
||||
|
||||
return data
|
||||
|
||||
|
||||
class HarvestClientImporter(FromHarvest, rattail_harvest_importing.model.HarvestClientImporter):
|
||||
"""
|
||||
|
|
Loading…
Reference in a new issue