From 43c49f23af9869b5a04da7c0e04b11b5243d9e34 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Fri, 22 Mar 2024 18:52:54 +0100 Subject: [PATCH] fix: ensure proper status in add charging stations op response MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- src/charging-station/ui-server/ui-services/AbstractUIService.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/charging-station/ui-server/ui-services/AbstractUIService.ts b/src/charging-station/ui-server/ui-services/AbstractUIService.ts index 6ba08807..ffdc2565 100644 --- a/src/charging-station/ui-server/ui-services/AbstractUIService.ts +++ b/src/charging-station/ui-server/ui-services/AbstractUIService.ts @@ -301,7 +301,7 @@ export abstract class AbstractUIService { } } return { - status: failedStationInfos.length > 0 ? ResponseStatus.FAILURE : ResponseStatus.SUCCESS, + status: err != null ? ResponseStatus.FAILURE : ResponseStatus.SUCCESS, ...(succeededStationInfos.length > 0 && { hashIdsSucceeded: succeededStationInfos.map(stationInfo => stationInfo.hashId) }), -- 2.34.1