Skip to content

Commit

Permalink
MDL-64889 completion: Fix performance of get_course_progress_percentage
Browse files Browse the repository at this point in the history
  • Loading branch information
Mark Johnson committed Feb 18, 2019
1 parent 1249995 commit 272c794
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion completion/classes/progress.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public static function get_course_progress_percentage($course, $userid = 0) {
// Get the number of modules that have been completed.
$completed = 0;
foreach ($modules as $module) {
$data = $completion->get_data($module, false, $userid);
$data = $completion->get_data($module, true, $userid);
$completed += $data->completionstate == COMPLETION_INCOMPLETE ? 0 : 1;
}

Expand Down

0 comments on commit 272c794

Please sign in to comment.