From 4da1b966e8e9fc41d5691a6a74efbca239b86af6 Mon Sep 17 00:00:00 2001 From: bdaloukas Date: Thu, 20 Dec 2012 01:35:36 +0200 Subject: [PATCH] Fix: creating new object --- lib.php | 1 + 1 file changed, 1 insertion(+) diff --git a/lib.php b/lib.php index 94262d0..9aa9d28 100755 --- a/lib.php +++ b/lib.php @@ -733,6 +733,7 @@ function game_num_attempt_summary($game, $cm, $returnzero = false, $currentgroup $numattempts = $DB->count_records('game_attempts', array('gameid'=> $game->id, 'preview'=>0)); if ($numattempts || $returnzero) { if (groups_get_activity_groupmode($cm)) { + $a = new stdClass(); $a->total = $numattempts; if ($currentgroup) { $a->group = $DB->count_records_sql('SELECT count(1) FROM ' .