From 2dd60f1c3d64e5bdd88bde97c10bd412cd6c12c8 Mon Sep 17 00:00:00 2001 From: Marc Runkel Date: Sun, 22 May 2016 11:08:26 +0200 Subject: [PATCH] This time, really fix it. --- includes/alerts/transport.hipchat.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/includes/alerts/transport.hipchat.php b/includes/alerts/transport.hipchat.php index 7a709cfa37..1bc9bd48c4 100644 --- a/includes/alerts/transport.hipchat.php +++ b/includes/alerts/transport.hipchat.php @@ -21,6 +21,7 @@ * @subpackage Alerts */ +// loop through each room foreach($opts as $option) { $url = $option['url']; foreach($obj as $key=>$value) { @@ -37,9 +38,11 @@ foreach($opts as $option) { } // Sane default of making the message color green if the message indicates - // that the alert recovered. - if(stripos($data["message"], "recovered")) { + // that the alert recovered. If it rebooted, make it yellow. + if(stripos($obj["msg"], "recovered")) { $color = "green"; + } elseif(stripos($obj["msg"], "rebooted")) { + $color = "yellow"; } else { $color = $option["color"]; }