From: Jérôme Benoit Date: Fri, 6 Jan 2023 22:09:08 +0000 (+0100) Subject: Remove now useless Date conversions to string X-Git-Tag: v1.1.89~20 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=aef5c03ddd1489b52df3801284d704342d60a41c;p=e-mobility-charging-stations-simulator.git Remove now useless Date conversions to string Signed-off-by: Jérôme Benoit --- diff --git a/src/charging-station/ocpp/1.6/OCPP16RequestService.ts b/src/charging-station/ocpp/1.6/OCPP16RequestService.ts index cf5ff237..f28f5f94 100644 --- a/src/charging-station/ocpp/1.6/OCPP16RequestService.ts +++ b/src/charging-station/ocpp/1.6/OCPP16RequestService.ts @@ -251,7 +251,7 @@ export default class OCPP16RequestService extends OCPPRequestService { meterStart: chargingStation.getEnergyActiveImportRegisterByConnectorId( commandParams?.connectorId as number ), - timestamp: new Date().toISOString(), + timestamp: new Date(), } as unknown as Request; case OCPP16RequestCommand.STOP_TRANSACTION: connectorId = chargingStation.getConnectorIdByTransactionId( @@ -269,7 +269,7 @@ export default class OCPP16RequestService extends OCPPRequestService { commandParams?.idTag ?? chargingStation.getTransactionIdTag(commandParams?.transactionId as number), meterStop: commandParams?.meterStop ?? energyActiveImportRegister, - timestamp: new Date().toISOString(), + timestamp: new Date(), reason: commandParams?.reason, ...(chargingStation.getTransactionDataMeterValues() && { transactionData: OCPP16ServiceUtils.buildTransactionDataMeterValues(