Better calendar import

This commit is contained in:
Emmy D'Anello 2024-02-10 19:54:27 +01:00
parent fd4157acbd
commit 22de576f53
Signed by: ynerant
GPG Key ID: 3A75C55819C8CF85
1 changed files with 1 additions and 2 deletions

View File

@ -177,8 +177,7 @@ class Command(BaseCommand):
end_date=calendar_dict['end_date'],
transport_type=transport_type,
)
calendars.append(calendar)
calendar_ids.append(calendar.id)
calendars[calendar.id] = calendar
if len(calendars) >= bulk_size and not dry_run:
Calendar.objects.bulk_create(calendars,