Merge branch 'MDL-31385_20' of git://github.com/timhunt/moodle into MOODLE_20_STABLE

This commit is contained in:
Aparup Banerjee
2012-01-30 12:51:25 +08:00
+1 -1
View File
@@ -64,7 +64,7 @@ if ($quizobj->is_preview_user() && $forcenew) {
}
/// Look for an existing attempt.
$attempts = quiz_get_user_attempts($quiz->id, $USER->id, 'all');
$attempts = quiz_get_user_attempts($quiz->id, $USER->id, 'all', true);
$lastattempt = end($attempts);
if ($lastattempt && !$lastattempt->timefinish) {