From d2176c83af8fa5f61ab0597eba6066bc12532f4d Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Thu, 8 Sep 2022 13:01:45 -0400 Subject: [PATCH] Restore status value to pre 1.36.16 value by substracting 1. So Unknown == -1, 0 = IDLE etc. Fixes #3584 --- web/api/app/Controller/MonitorsController.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/web/api/app/Controller/MonitorsController.php b/web/api/app/Controller/MonitorsController.php index 193e8a61a..c633ae0ca 100644 --- a/web/api/app/Controller/MonitorsController.php +++ b/web/api/app/Controller/MonitorsController.php @@ -299,6 +299,8 @@ class MonitorsController extends AppController { '_serialize' => array('status','code','error'), )); } else { + // In 1.36.16 the values got shifted up so that we could index into an array of strings. + $status -= 1; $this->set(array( 'status' => $status, 'output' => implode(PHP_EOL, $output),