Permalink
Browse files

MDL-27314 quiz attempts cannot be deleted in separate groups mode.

  • Loading branch information...
1 parent 2af51a1 commit 8f64668af2fb801a1803f8f62e1b18eaabd5a4bb @tigusigalpa tigusigalpa committed with stronk7 Dec 1, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 mod/quiz/report/attemptsreport.php
View
2 mod/quiz/report/attemptsreport.php
@@ -360,7 +360,7 @@ protected function delete_selected_attempts($quiz, $cm, $attemptids, $allowed) {
// Ensure the attempt exists, and belongs to this quiz. If not skip.
continue;
}
- if ($allowed && !array_key_exists($attempt->userid, $allowed)) {
+ if ($allowed && !in_array($attempt->userid, $allowed)) {
// Ensure the attempt belongs to a student included in the report. If not skip.
continue;
}

0 comments on commit 8f64668

Please sign in to comment.