mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
MDL-52649 user: Add check for potentially undefined variables
This commit is contained in:
parent
ef343c3299
commit
9488b6f3a4
@ -512,12 +512,12 @@ if ($roleid > 0) {
|
||||
$a->role = $rolenames[$roleid];
|
||||
$heading = format_string(get_string('xuserswiththerole', 'role', $a));
|
||||
|
||||
if ($currentgroup and $group) {
|
||||
if ($currentgroup and !empty($group)) {
|
||||
$a->group = $group->name;
|
||||
$heading .= ' ' . format_string(get_string('ingroup', 'role', $a));
|
||||
}
|
||||
|
||||
if ($accesssince) {
|
||||
if ($accesssince && !empty($timeoptions[$accesssince])) {
|
||||
$a->timeperiod = $timeoptions[$accesssince];
|
||||
$heading .= ' ' . format_string(get_string('inactiveformorethan', 'role', $a));
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user