From eaad6e5cf27bf830e4c2ac3a68003a5c09979f23 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Fri, 23 Dec 2022 22:07:23 +0100 Subject: [PATCH] Refine some templates handling log messages MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- src/charging-station/ChargingStation.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/charging-station/ChargingStation.ts b/src/charging-station/ChargingStation.ts index 01e34060..20122c40 100644 --- a/src/charging-station/ChargingStation.ts +++ b/src/charging-station/ChargingStation.ts @@ -796,7 +796,7 @@ export default class ChargingStation { private getStationInfoFromTemplate(): ChargingStationInfo { const stationTemplate: ChargingStationTemplate = this.getTemplateFromFile(); if (Utils.isNullOrUndefined(stationTemplate)) { - const errorMsg = 'Failed to read charging station template file'; + const errorMsg = `Failed to read charging station template file ${this.templateFile}`; logger.error(`${this.logPrefix()} ${errorMsg}`); throw new BaseError(errorMsg); } @@ -828,7 +828,9 @@ export default class ChargingStation { logger.warn( `${this.logPrefix()} Firmware version '${ stationTemplate.firmwareVersion - }' does not match regular expression '${firmwareVersionRegExp.toString()}'` + }' in template file ${ + this.templateFile + } does not match regular expression '${firmwareVersionRegExp.toString()}'` ); } const stationInfo: ChargingStationInfo = -- 2.34.1