Fix unit conversion.
[e-mobility-charging-stations-simulator.git] / src / charging-station / ChargingStation.js
index 3e0f9bfcdfc73ab236e6ac7daf6a8609ef0875e6..1f5c9b45d9c25568fa2c2d93d5709c41b46694da 100644 (file)
@@ -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);