From b57115d885b67a95cc61452ce70b291a1eeb65a9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Sun, 2 May 2021 22:33:58 +0200 Subject: [PATCH] src/utils/PerformanceStatistics.ts: Use commands enum MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- src/utils/PerformanceStatistics.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/utils/PerformanceStatistics.ts b/src/utils/PerformanceStatistics.ts index d7a4388e..515467a6 100644 --- a/src/utils/PerformanceStatistics.ts +++ b/src/utils/PerformanceStatistics.ts @@ -113,9 +113,9 @@ export default class PerformanceStatistics { private addPerformanceTimer(command: RequestCommand | IncomingRequestCommand, duration: number): void { // Map to proper command name const MAPCOMMAND = { - sendMeterValues: 'MeterValues', - startTransaction: 'StartTransaction', - stopTransaction: 'StopTransaction', + sendMeterValues: RequestCommand.METERVALUES, + startTransaction: RequestCommand.START_TRANSACTION, + stopTransaction: RequestCommand.STOP_TRANSACTION, }; if (MAPCOMMAND[command]) { command = MAPCOMMAND[command] as RequestCommand | IncomingRequestCommand; -- 2.34.1