From: Jérôme Benoit Date: Fri, 23 Dec 2022 21:07:23 +0000 (+0100) Subject: Refine some templates handling log messages X-Git-Tag: v1.1.89~56 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=eaad6e5cf27bf830e4c2ac3a68003a5c09979f23;p=e-mobility-charging-stations-simulator.git Refine some templates handling log messages Signed-off-by: Jérôme Benoit --- 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 =