From: Jérôme Benoit Date: Fri, 26 Aug 2022 22:23:47 +0000 (+0200) Subject: UI server: comment and code cleanups X-Git-Tag: v1.1.68~26 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=49bc4b806d6320bfb011d3a2c7fee843fb5f7e9c;p=e-mobility-charging-stations-simulator.git UI server: comment and code cleanups Signed-off-by: Jérôme Benoit --- diff --git a/src/charging-station/ui-server/UIHttpServer.ts b/src/charging-station/ui-server/UIHttpServer.ts index 98a1a495..0731b3c0 100644 --- a/src/charging-station/ui-server/UIHttpServer.ts +++ b/src/charging-station/ui-server/UIHttpServer.ts @@ -59,7 +59,7 @@ export default class UIHttpServer extends AbstractUIServer { break; } if (this.responseHandlers.has(uuid)) { - const { procedureName, res } = this.responseHandlers.get(uuid); + const { res } = this.responseHandlers.get(uuid); res.writeHead(statusCode, { 'Content-Type': 'application/json' }); res.write(JSON.stringify(payload)); res.end(); diff --git a/src/charging-station/ui-server/ui-services/AbstractUIService.ts b/src/charging-station/ui-server/ui-services/AbstractUIService.ts index e27577d3..24307992 100644 --- a/src/charging-station/ui-server/ui-services/AbstractUIService.ts +++ b/src/charging-station/ui-server/ui-services/AbstractUIService.ts @@ -103,8 +103,7 @@ export default abstract class AbstractUIService { return JSON.stringify([messageId, responsePayload] as ProtocolResponse); } - // Validate the raw data received from the WebSocket - // TODO: should probably be moved to the ws verify clients callback + // Validate the raw data received from the UI server private requestValidation(rawData: RawData | JsonType): ProtocolRequest { // logger.debug( // `${this.logPrefix(