From: Jérôme Benoit Date: Tue, 31 Aug 2021 15:25:12 +0000 (+0200) Subject: Fix remote start transactiion: connection status can be preparing X-Git-Tag: v1.0.52~1 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=ec26ac96d0442ea40c8597e09382f66f6d630da4;p=e-mobility-charging-stations-simulator.git Fix remote start transactiion: connection status can be preparing Signed-off-by: Jérôme Benoit --- diff --git a/src/charging-station/ocpp/1.6/OCPP16ResponseService.ts b/src/charging-station/ocpp/1.6/OCPP16ResponseService.ts index fa015906..985870d2 100644 --- a/src/charging-station/ocpp/1.6/OCPP16ResponseService.ts +++ b/src/charging-station/ocpp/1.6/OCPP16ResponseService.ts @@ -56,7 +56,8 @@ export default class OCPP16ResponseService extends OCPPResponseService { logger.debug(this.chargingStation.logPrefix() + ' Trying to start a transaction on an already used connector ' + connectorId.toString() + ': %j', this.chargingStation.getConnector(connectorId)); return; } - if (this.chargingStation.getConnector(connectorId)?.status !== OCPP16ChargePointStatus.AVAILABLE) { + if (this.chargingStation.getConnector(connectorId)?.status !== OCPP16ChargePointStatus.AVAILABLE + || this.chargingStation.getConnector(connectorId)?.status !== OCPP16ChargePointStatus.PREPARING) { logger.error(`${this.chargingStation.logPrefix()} Trying to start a transaction on connector ${connectorId.toString()} with status ${this.chargingStation.getConnector(connectorId)?.status}`); return; }