diff --git a/district/management/commands/octopus_people_import.py b/district/management/commands/octopus_people_import.py index 3229e64e255edd497b154249cd049311d859ca4e..48ee4ca9c9c86a90c2a17ce9e926c442495f705b 100644 --- a/district/management/commands/octopus_people_import.py +++ b/district/management/commands/octopus_people_import.py @@ -52,5 +52,9 @@ class Command(BaseCommand): for person_page in DistrictManualOctopusPersonPage.objects.all(): import_manual_person.delay( - person_page.id, person_page.root_page.image_collection_id + person_page.id, ( + person_page.root_page.image_collection_id + if hasattr(person_page.root_page, "image_collection_id") + else 0 + ) )