Permalink
Browse files

MDL-37559 fix display of multiple roles of other users

Credit goes to Tyron Delean, thanks.
  • Loading branch information...
1 parent e61f96c commit bb92d9053c400af53b1e42797bfbc78ed8862ed5 @skodak skodak committed Jan 19, 2013
Showing with 3 additions and 1 deletion.
  1. +3 −1 enrol/locallib.php
View
@@ -792,7 +792,9 @@ public function get_other_users_for_display(core_enrol_renderer $renderer, moodl
break;
}
}
- $users[$userrole->id]['roles'] = array();
+ if (!isset($users[$userrole->id]['roles'])) {
+ $users[$userrole->id]['roles'] = array();
+ }
$users[$userrole->id]['roles'][$userrole->roleid] = array(
'text' => $roletext,
'unchangeable' => !$changeable

0 comments on commit bb92d90

Please sign in to comment.