Browse code

browse/ratings.php: fix Undefined variable warning for ratingslist in PHP 8 - sub-issue of previous Uncaught TypeError message in PHP 8

Clarissa Walker authored on 2026/09/06 16:47:59
Showing 1 changed files
... ...
@@ -34,7 +34,7 @@ if($rating) {
34 34
 }
35 35
 else {
36 36
 	$output .= "<div id='pagetitle'>"._RATINGS."</div>";
37
-	$total = is_countable($ratingslist);
37
+	$total = is_countable($ratingslist ?? null);
38 38
 	$count = 0;
39 39
 	$column = 1;
40 40
 	$list = floor($total / $displaycolumns);