chargingStation: ChargingStation,
connectorId: number,
status: OCPP16ChargePointStatus
- ): void {
+ ): boolean {
if (
connectorId === 0 &&
!OCPP16Constants.OCPP16ChargePointStatusChargingStationTransition.has([
chargingStation.getConnectorStatus(connectorId).status
} to ${status} is not allowed`
);
+ return false;
} else if (
!OCPP16Constants.OCPP16ChargePointStatusConnectorTransition.has([
chargingStation.getConnectorStatus(connectorId).status as OCPP16ChargePointStatus,
chargingStation.getConnectorStatus(connectorId).status
} to ${status} is not allowed`
);
+ return false;
}
+ return true;
}
private static buildSampledValue(