From 9520fd9481c2e9dfcff08f9a18d9c8a1237db28e Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Mon, 19 Jun 2023 13:06:48 -0600 Subject: [PATCH] Update switch_status.php a few PHP 8.1 changes --- app/switch/resources/dashboard/switch_status.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/app/switch/resources/dashboard/switch_status.php b/app/switch/resources/dashboard/switch_status.php index 833b1ef6f2..2276723cf5 100644 --- a/app/switch/resources/dashboard/switch_status.php +++ b/app/switch/resources/dashboard/switch_status.php @@ -53,6 +53,7 @@ } //channel count + $tr_link_channels = ''; if (permission_exists('switch_channels') && $fp) { $tmp = event_socket_request($fp, 'api status'); $matches = Array(); @@ -64,6 +65,7 @@ } //registration count + $registrations = ''; if (permission_exists('switch_registrations') && file_exists($_SERVER["DOCUMENT_ROOT"].PROJECT_PATH."/app/registrations/")) { $registration = new registrations; if (permission_exists("registration_all")) { @@ -125,7 +127,7 @@ echo "\n"; //switch version - if (permission_exists('switch_version') && $switch_version != '') { + if (permission_exists('switch_version') && !empty($switch_version)) { echo "\n"; echo "".$text['label-switch']."\n"; echo "".$switch_version." (".$switch_bits.")\n"; @@ -134,7 +136,7 @@ } //switch uptime - if (permission_exists('switch_uptime') && $uptime != '') { + if (permission_exists('switch_uptime') && !empty($uptime)) { echo "\n"; echo "".$text['label-switch_uptime']."\n"; echo "".$uptime."\n"; @@ -167,4 +169,4 @@ echo ""; echo "\n"; -?> \ No newline at end of file +?>