diff --git a/lib.php b/lib.php index e78c038..5f29854 100644 --- a/lib.php +++ b/lib.php @@ -247,7 +247,7 @@ function local_treestudyplan_find_cohortmembers($cohortid) { global $DB; // By default wherecondition retrieves all users except the deleted, not confirmed and guest. - $params['cohortid'] = $cohortid; + $params = ['cohortid' => $cohortid]; $sql = "SELECT * FROM {user} u JOIN {cohort_members} cm ON (cm.userid = u.id AND cm.cohortid = :cohortid) WHERE u.suspended = 0 AND u.id > 1