From b0c1f80fc7bda3ce45dda1b2008eb8ce16232082 Mon Sep 17 00:00:00 2001 From: jh23453 Date: Sun, 6 Mar 2022 21:13:50 +0100 Subject: [PATCH] Fix php8 error in function.php I got the message: PHP Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /usr/share/ganglia-webfrontend/functions.php on line 732 This messages is likely new with php7.3. Will be an error with PHP8. For details see https://wiki.php.net/rfc/continue_on_switch_deprecation This in one small step to get ready for php8. See https://github.com/ganglia/ganglia-web/issues/361 --- functions.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions.php b/functions.php index afbb5862..c2dc21e7 100644 --- a/functions.php +++ b/functions.php @@ -729,7 +729,7 @@ function get_view_graph_elements($view) { case "standard": // Does view have any items/graphs defined if ( count($view['items']) == 0 ) { - continue; + break; // print "No graphs defined for this view. Please add some"; } else { // Loop through graph items