repositories
/
e-mobility-charging-stations-simulator.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
refactor(simulator): remove unneeded condition check in log message
[e-mobility-charging-stations-simulator.git]
/
src
/
charging-station
/
ocpp
/
OCPPRequestService.ts
diff --git
a/src/charging-station/ocpp/OCPPRequestService.ts
b/src/charging-station/ocpp/OCPPRequestService.ts
index 0f05d9a3d53082f210eaf93c1225ed04b78f2d0a..4115eff1144f1c50a91e79f7197632f47fd6e553 100644
(file)
--- a/
src/charging-station/ocpp/OCPPRequestService.ts
+++ b/
src/charging-station/ocpp/OCPPRequestService.ts
@@
-275,7
+275,7
@@
export abstract class OCPPRequestService {
ErrorType.GENERIC_ERROR,
`WebSocket closed or errored for buffered message id '${messageId}' with content '${messageToSend}'`,
commandName,
ErrorType.GENERIC_ERROR,
`WebSocket closed or errored for buffered message id '${messageId}' with content '${messageToSend}'`,
commandName,
- (messagePayload as JsonObject)?.details ??
{}
+ (messagePayload as JsonObject)?.details ??
Constants.EMPTY_FREEZED_OBJECT
)
);
} else if (wsClosedOrErrored) {
)
);
} else if (wsClosedOrErrored) {
@@
-283,7
+283,7
@@
export abstract class OCPPRequestService {
ErrorType.GENERIC_ERROR,
`WebSocket closed or errored for non buffered message id '${messageId}' with content '${messageToSend}'`,
commandName,
ErrorType.GENERIC_ERROR,
`WebSocket closed or errored for non buffered message id '${messageId}' with content '${messageToSend}'`,
commandName,
- (messagePayload as JsonObject)?.details ??
{}
+ (messagePayload as JsonObject)?.details ??
Constants.EMPTY_FREEZED_OBJECT
);
// Reject response
if (messageType !== MessageType.CALL_MESSAGE) {
);
// Reject response
if (messageType !== MessageType.CALL_MESSAGE) {
@@
-358,7
+358,7
@@
export abstract class OCPPRequestService {
ErrorType.GENERIC_ERROR,
`Timeout for message id '${messageId}'`,
commandName,
ErrorType.GENERIC_ERROR,
`Timeout for message id '${messageId}'`,
commandName,
- (messagePayload as JsonObject)?.details ??
{}
+ (messagePayload as JsonObject)?.details ??
Constants.EMPTY_FREEZED_OBJECT
),
() => {
messageType === MessageType.CALL_MESSAGE && chargingStation.requests.delete(messageId);
),
() => {
messageType === MessageType.CALL_MESSAGE && chargingStation.requests.delete(messageId);