From b25fabf52b7cad51a9d3d69be7cea0ceae6385f6 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Mon, 10 Nov 2025 21:56:29 +0000 Subject: [PATCH] fix(alert_discord): reorder fields in Discord alert JSON * Changed the order of fields in the Discord alert JSON structure. * Updated the "More info" and "Is my Game Server Online?" fields for better clarity. --- lgsm/modules/alert_discord.sh | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/lgsm/modules/alert_discord.sh b/lgsm/modules/alert_discord.sh index bd8e8b58c..a445cf813 100644 --- a/lgsm/modules/alert_discord.sh +++ b/lgsm/modules/alert_discord.sh @@ -43,34 +43,33 @@ json=$( "inline": true }, { - "name": "Server Time", - "value": "$(date)", + "name": "Address:Port", + "value": "\`${alertip}:${port}\`", "inline": true } EOF ) -if [ -n "${querytype}" ]; then +if [ -n "${alerturl}" ]; then json+=$( cat << EOF , { - "name": "Is my Game Server Online?", - "value": "https://ismygameserver.online/${imgsoquerytype}/${alertip}:${queryport}", + "name": "More info", + "value": "${alerturl}", "inline": true } EOF ) fi -if [ -n "${alerturl}" ]; then +if [ -n "${querytype}" ]; then json+=$( cat << EOF , { - "name": "More info", - "value": "${alerturl}", - "inline": true + "name": "Is my Game Server Online?", + "value": "https://ismygameserver.online/${imgsoquerytype}/${alertip}:${queryport}" } EOF )