From: Jérôme Benoit Date: Mon, 19 Oct 2020 14:43:32 +0000 (+0200) Subject: Fix unit conversion. X-Git-Tag: v1.0.1-0~271 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=35f9a03131aef90757c4be730e5e89b44e478c46;p=e-mobility-charging-stations-simulator.git Fix unit conversion. Signed-off-by: Jérôme Benoit --- diff --git a/src/charging-station/ChargingStation.js b/src/charging-station/ChargingStation.js index 3e0f9bfc..1f5c9b45 100644 --- a/src/charging-station/ChargingStation.js +++ b/src/charging-station/ChargingStation.js @@ -95,8 +95,8 @@ class ChargingStation { logger.debug(this._basicFormatLog() + ' Template file ' + this._stationTemplateFile + ' have changed, reload'); // Initialize this._initialize(); - this._addConfigurationKey('HeartBeatInterval', Utils.convertToInt(this._heartbeatInterval ? this._heartbeatInterval : 0)); - this._addConfigurationKey('HeartbeatInterval', Utils.convertToInt(this._heartbeatInterval ? this._heartbeatInterval : 0), false, false); + this._addConfigurationKey('HeartBeatInterval', Utils.convertToInt(this._heartbeatInterval ? this._heartbeatInterval / 1000 : 0)); + this._addConfigurationKey('HeartbeatInterval', Utils.convertToInt(this._heartbeatInterval ? this._heartbeatInterval / 1000 : 0), false, false); this._addConfigurationKey('NumberOfConnectors', this._getMaxConnectors(), true); } catch (error) { logger.error(this._basicFormatLog() + ' Charging station template file monitoring error: ' + error);