From: Jérôme Benoit Date: Sun, 28 Jan 2024 18:42:15 +0000 (+0100) Subject: fix: ensure WS connection retry flag is reset in all connection case X-Git-Tag: v1.2.33~11 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=3f597174fae8645574c7ee0be9f0f98a0aad476a;p=e-mobility-charging-stations-simulator.git fix: ensure WS connection retry flag is reset in all connection case Signed-off-by: Jérôme Benoit --- diff --git a/src/charging-station/ChargingStation.ts b/src/charging-station/ChargingStation.ts index 2c683058..5c3c13c7 100644 --- a/src/charging-station/ChargingStation.ts +++ b/src/charging-station/ChargingStation.ts @@ -225,6 +225,9 @@ export class ChargingStation extends EventEmitter { }) this.wsConnectionRetried = false }) + this.on(ChargingStationEvents.rejected, () => { + this.wsConnectionRetried = false + }) this.on(ChargingStationEvents.disconnected, () => { try { this.internalStopMessageSequence()