From 89a2ae8e91af0f5a9caabaad6d7ff6915e59ce29 Mon Sep 17 00:00:00 2001 From: Pargorn Ruasijan Date: Sat, 25 Jan 2025 15:50:57 +0700 Subject: [PATCH] Update server/notification-providers/onechat.js Co-authored-by: Frank Elsinga --- server/notification-providers/onechat.js | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/server/notification-providers/onechat.js b/server/notification-providers/onechat.js index 463ef9786..0c675b961 100644 --- a/server/notification-providers/onechat.js +++ b/server/notification-providers/onechat.js @@ -33,17 +33,11 @@ class OneChat extends NotificationProvider { bot_id: notification.botId, type: "text", message: - "UptimeKuma Alert:\n" + - "[🔴 Down]\n" + - "Name: " + - monitorJSON["name"] + - "\n" + - heartbeatJSON["msg"] + - "\n" + - "Time (" + - heartbeatJSON["timezone"] + - "): " + - heartbeatJSON["localDateTime"], + `UptimeKuma Alert: +[🔴 Down] +Name: ${monitorJSON["name"]} +${heartbeatJSON["msg"]} +Time (${heartbeatJSON["timezone"]}): ${heartbeatJSON["localDateTime"]}`, }; await axios.post(url, downMessage, config); } else if (heartbeatJSON["status"] === UP) {