diff --git a/src/agenda_culturel/models.py b/src/agenda_culturel/models.py index 7fa4926..1d90539 100644 --- a/src/agenda_culturel/models.py +++ b/src/agenda_culturel/models.py @@ -1988,7 +1988,7 @@ class Event(models.Model): # check if the event has already be imported (using uuid) same_events = event.find_same_events_by_uuid() - if len(same_events) != 0: + if same_events is not None and len(same_events) != 0: # check if one event has been imported and not modified in this list same_imported = Event.find_last_pure_import(same_events) pure = True