Skip to content

Commit 8904b10

Browse files
author
David Monllao
committed
Merge branch 'MDL-61236-33' of git://github.com/farhan6318/moodle into MOODLE_33_STABLE
2 parents 235d4be + 055010a commit 8904b10

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

enrol/self/lib.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1031,8 +1031,9 @@ public function get_welcome_email_contact($sendoption, $context) {
10311031
// We only use the first user.
10321032
$i = 0;
10331033
do {
1034-
$rusers = get_role_users($croles[$i], $context, true, '',
1035-
'r.sortorder ASC, ' . $sort, null, '', '', '', '', $sortparams);
1034+
$allnames = get_all_user_name_fields(true, 'u');
1035+
$rusers = get_role_users($croles[$i], $context, true, 'u.id, u.confirmed, u.username, '. $allnames . ',
1036+
u.email, r.sortorder, ra.id', 'r.sortorder, ra.id ASC, ' . $sort, null, '', '', '', '', $sortparams);
10361037
$i++;
10371038
} while (empty($rusers) && !empty($croles[$i]));
10381039
}

0 commit comments

Comments
 (0)