From 887a125e6db5e0457e653b3c6848d18214558813 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Mon, 5 Feb 2024 22:56:31 +0100 Subject: [PATCH] fix: fix worker event error handling MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- src/charging-station/Bootstrap.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/charging-station/Bootstrap.ts b/src/charging-station/Bootstrap.ts index 98cadb84..07d411b5 100644 --- a/src/charging-station/Bootstrap.ts +++ b/src/charging-station/Bootstrap.ts @@ -152,10 +152,10 @@ export class Bootstrap extends EventEmitter { ) this.on( ChargingStationWorkerMessageEvents.workerElementError, - (msg: ChargingStationWorkerMessage) => { + (eventError: ChargingStationWorkerEventError) => { logger.error( - `${this.logPrefix()} ${moduleName}.messageHandler: Error occurred while handling '${msg.data.event}' event on worker:`, - msg.data + `${this.logPrefix()} ${moduleName}.messageHandler: Error occurred while handling '${eventError.event}' event on worker:`, + eventError ) } ) -- 2.34.1