Permalink
Browse files

Merge branch 'MDL-37473-24' of git://github.com/srynot4sale/moodle in…

…to MOODLE_24_STABLE
  • Loading branch information...
2 parents 3a6152c + 349fc3e commit f5222c7416a169d1dcfa8349c3196a24f3111484 @danpoltawski danpoltawski committed Jan 22, 2013
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/completionlib.php
@@ -1021,7 +1021,7 @@ public function get_activities($modinfo=null) {
* @return bool
*/
public function is_tracked_user($userid) {
- return is_enrolled(context_course::instance($this->course->id), $userid, '', true);
+ return is_enrolled(context_course::instance($this->course->id), $userid, 'moodle/course:isincompletionreports', true);
}
/**
@@ -1038,7 +1038,7 @@ public function get_num_tracked_users($where = '', $whereparams = array(), $grou
global $DB;
list($enrolledsql, $enrolledparams) = get_enrolled_sql(
- context_course::instance($this->course->id), '', $groupid, true);
+ context_course::instance($this->course->id), 'moodle/course:isincompletionreports', $groupid, true);
$sql = 'SELECT COUNT(eu.id) FROM (' . $enrolledsql . ') eu JOIN {user} u ON u.id = eu.id';
if ($where) {
$sql .= " WHERE $where";

0 comments on commit f5222c7

Please sign in to comment.