From e5578183ec774f4715040f5cf63c900d6928c1eb Mon Sep 17 00:00:00 2001 From: Thomas Vincent Date: Thu, 9 Apr 2026 13:58:38 -0700 Subject: [PATCH 1/4] refactor: add strict typing and clean up standalone infra --- .omc/sessions/42a5a3ed-3430-434f-addf-dc7423bda6d8.json | 8 ++++++++ .omc/sessions/859688d5-ece7-4d1e-ab13-c82d820e7440.json | 8 ++++++++ cycle.php | 2 ++ functions.php | 2 ++ images/index.php | 2 ++ index.php | 2 ++ locales/LC_MESSAGES/index.php | 2 ++ locales/index.php | 2 ++ setup.php | 2 ++ 9 files changed, 30 insertions(+) create mode 100644 .omc/sessions/42a5a3ed-3430-434f-addf-dc7423bda6d8.json create mode 100644 .omc/sessions/859688d5-ece7-4d1e-ab13-c82d820e7440.json diff --git a/.omc/sessions/42a5a3ed-3430-434f-addf-dc7423bda6d8.json b/.omc/sessions/42a5a3ed-3430-434f-addf-dc7423bda6d8.json new file mode 100644 index 0000000..9fe44b6 --- /dev/null +++ b/.omc/sessions/42a5a3ed-3430-434f-addf-dc7423bda6d8.json @@ -0,0 +1,8 @@ +{ + "session_id": "42a5a3ed-3430-434f-addf-dc7423bda6d8", + "ended_at": "2026-04-09T20:11:48.000Z", + "reason": "other", + "agents_spawned": 0, + "agents_completed": 0, + "modes_used": [] +} \ No newline at end of file diff --git a/.omc/sessions/859688d5-ece7-4d1e-ab13-c82d820e7440.json b/.omc/sessions/859688d5-ece7-4d1e-ab13-c82d820e7440.json new file mode 100644 index 0000000..9309dfa --- /dev/null +++ b/.omc/sessions/859688d5-ece7-4d1e-ab13-c82d820e7440.json @@ -0,0 +1,8 @@ +{ + "session_id": "859688d5-ece7-4d1e-ab13-c82d820e7440", + "ended_at": "2026-04-09T19:59:02.981Z", + "reason": "other", + "agents_spawned": 0, + "agents_completed": 0, + "modes_used": [] +} \ No newline at end of file diff --git a/cycle.php b/cycle.php index fc996d1..30711f8 100644 --- a/cycle.php +++ b/cycle.php @@ -1,4 +1,6 @@ Date: Thu, 9 Apr 2026 14:02:17 -0700 Subject: [PATCH 2/4] refactor: safe PHP 7.4 modernization (arrays, null coalescing) --- cycle.php | 6 +++--- functions.php | 32 ++++++++++++++++---------------- setup.php | 4 ++-- 3 files changed, 21 insertions(+), 21 deletions(-) diff --git a/cycle.php b/cycle.php index 30711f8..733d902 100644 --- a/cycle.php +++ b/cycle.php @@ -79,7 +79,7 @@ function cycle_graphs() { if (empty($id)) $id = -1; /* get the start and end times for the graph */ - $timespan = array(); + $timespan = []; $first_weekdayid = read_user_setting('first_weekdayid'); get_timespan($timespan, time(), get_request_var('timespan'), $first_weekdayid); @@ -178,7 +178,7 @@ function cycle() { } /* get the start and end times for the graph */ - $timespan = array(); + $timespan = []; $first_weekdayid = read_user_setting('first_weekdayid'); get_timespan($timespan, time(), get_request_var('timespan') , $first_weekdayid); @@ -302,7 +302,7 @@ function cycle() { WHERE title != "" AND graph_tree_id = ? ORDER BY parent, position', - array($graph_tree)); + [$graph_tree]); if (cacti_sizeof($leaves)) { $html .= "