From eba55c35e215aefd8877d5ed51165e10ecc3dca8 Mon Sep 17 00:00:00 2001 From: Phael Mouko Date: Mon, 16 Dec 2024 09:47:42 +0100 Subject: [PATCH] SPSH-1574: Fixed the issue with data-items being saved two times --- src/modules/import/domain/import-event-handler.ts | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/modules/import/domain/import-event-handler.ts b/src/modules/import/domain/import-event-handler.ts index b1be7df08..a7f962a9b 100644 --- a/src/modules/import/domain/import-event-handler.ts +++ b/src/modules/import/domain/import-event-handler.ts @@ -53,7 +53,6 @@ export class ImportEventHandler { } }); - const importDataItemsWithLoginInfo: ImportDataItem[] = []; const importvorgangId: string = event.importVorgangId; const importVorgang: Option> = await this.importVorgangRepository.findById(importvorgangId); if (!importVorgang) { @@ -77,12 +76,6 @@ export class ImportEventHandler { ); } - await Promise.allSettled( - importDataItemsWithLoginInfo.map(async (importDataItem: ImportDataItem) => - this.importDataRepository.save(importDataItem), - ), - ); - importVorgang.finish(); await this.importVorgangRepository.save(importVorgang); }