From 35dec5e81e1a5562d75d6f2927795f1252a70c5c Mon Sep 17 00:00:00 2001 From: Leander Date: Fri, 21 Apr 2017 09:23:35 +0200 Subject: [PATCH] T201704210923 --- allhighscores.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/allhighscores.php b/allhighscores.php index dac0fb0..9cda715 100644 --- a/allhighscores.php +++ b/allhighscores.php @@ -31,7 +31,7 @@ if($cid == -1) { LIMIT $2 OFFSET $3', array($cid, $limit, $offset))['data']; foreach($overview as $row) { $name = $row['name']; - $score = $score != NULL ? ($row['score']) : -1; + $score = (isset($score) AND $score != NULL) ? ($row['score']) : -1; $place = $db->query('SELECT COUNT(*) FROM "Highscores" WHERE "score" > $1 AND "Categories_ID" = $2', array($score, $cid))['data'][0]['count'] + 1; $data[] = array('place' => $place, 'name' => $name, 'score' => $score);