changed code to use get_role_users function

This commit is contained in:
toyomoyo 2006-09-12 07:38:07 +00:00
parent ab5c904411
commit 87e5a0cd9e

View file

@ -123,9 +123,7 @@
$existinguserarray = array();
$SQL = "select u.* from {$CFG->prefix}role_assignments r, {$CFG->prefix}user u where contextid = $context->id and roleid = $roleid and u.id = r.userid"; // join now so that we can just use fullname() later
if (!$contextusers = get_records_sql($SQL)) {
if (!$contextusers = get_role_users($roleid, $context)) {
$contextusers = array();
}