Track OCPP commande use at sending error message
[e-mobility-charging-stations-simulator.git] / src / charging-station / ui-websocket-services / UIServiceUtils.ts
index e71b5f339e2349d245530a5f21754279389a6ed8..2c37e80a4f9b2cc743a7b468b0d96fa9d284290b 100644 (file)
@@ -2,7 +2,7 @@ import { Protocol, ProtocolVersion } from '../../types/UIProtocol';
 
 import { IncomingMessage } from 'http';
 import Utils from '../../utils/Utils';
-import getLogger from '../../utils/Logger';
+import logger from '../../utils/Logger';
 
 export class UIServiceUtils {
   public static handleProtocols = (protocols: Set<string>, request: IncomingMessage): string | false => {
@@ -17,7 +17,7 @@ export class UIServiceUtils {
         return fullProtocol;
       }
     }
-    getLogger().error(`${Utils.logPrefix(' UI WebSocket Server:')} Unsupported protocol: ${protocol} or protocol version: ${version}`);
+    logger.error(`${Utils.logPrefix(' UI WebSocket Server:')} Unsupported protocol: ${protocol} or protocol version: ${version}`);
     return false;
   };
 }