From c121ff6bc58048bd94e3d02a7d084bffd16a87e6 Mon Sep 17 00:00:00 2001 From: joseph le Date: Sat, 21 Oct 2023 08:10:19 +0700 Subject: [PATCH] update lib power --- app/utils/powerSchedule.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/utils/powerSchedule.js b/app/utils/powerSchedule.js index c8c1eaa..df5ce71 100644 --- a/app/utils/powerSchedule.js +++ b/app/utils/powerSchedule.js @@ -73,10 +73,11 @@ const { addLogFunction } = require("./addLogFunctionJS"); }; client.messages.send(params); } - }, 5000); - const fileName = + const fileName = "/home/Log_service/app/store/logsAPI/" + moment(Date.now()).format("DD_MM_YYYY").toString() + ".log"; addLogFunction(fileName, JSON.stringify(params, null, 2), "powerSchedule") + }, 5000); + })();