DataTransferStatus,
type DiagnosticsStatusNotificationRequest,
type DiagnosticsStatusNotificationResponse,
+ type EmptyObject,
type FirmwareStatusNotificationRequest,
type FirmwareStatusNotificationResponse,
type HeartbeatRequest,
const moduleName = 'ChargingStationWorkerBroadcastChannel';
type CommandResponse =
+ | EmptyObject
| StartTransactionResponse
| StopTransactionResponse
| AuthorizeResponse
| BootNotificationResponse
- | StatusNotificationResponse
| HeartbeatResponse
| DataTransferResponse;
}
const [uuid, command, requestPayload] = validatedMessageEvent.data as BroadcastChannelRequest;
if (
- !isNullOrUndefined(requestPayload?.hashIds) &&
- requestPayload?.hashIds?.includes(this.chargingStation.stationInfo.hashId) === false
+ !isNullOrUndefined(requestPayload.hashIds) &&
+ requestPayload.hashIds?.includes(this.chargingStation.stationInfo.hashId) === false
) {
return;
}
- if (!isNullOrUndefined(requestPayload?.hashId)) {
+ if (!isNullOrUndefined(requestPayload.hashId)) {
logger.error(
`${this.chargingStation.logPrefix()} ${moduleName}.requestHandler: 'hashId' field usage in PDU is deprecated, use 'hashIds' array instead`,
);