|
@@ 88-93 (lines=6) @@
|
| 85 |
|
$cm = get_coursemodule_from_instance('bigbluebuttonbn', $bigbluebuttonbn->id, $course->id, false, MUST_EXIST); |
| 86 |
|
|
| 87 |
|
//User roles |
| 88 |
|
if ($bigbluebuttonbn->participants == null || $bigbluebuttonbn->participants == '' || $bigbluebuttonbn->participants == '[]') { |
| 89 |
|
//The room that is being used comes from a previous version |
| 90 |
|
$moderator = has_capability('mod/bigbluebuttonbn:moderate', $context); |
| 91 |
|
} else { |
| 92 |
|
$moderator = bigbluebuttonbn_is_moderator($USER->id, get_user_roles($context, $USER->id, true), $bigbluebuttonbn->participants); |
| 93 |
|
} |
| 94 |
|
$administrator = has_capability('moodle/category:manage', $context); |
| 95 |
|
|
| 96 |
|
if ($moderator || $administrator) { |
|
@@ 115-120 (lines=6) @@
|
| 112 |
|
$cm = get_coursemodule_from_id('bigbluebuttonbn', $bigbluebuttonbn->coursemodule, 0, false, MUST_EXIST); |
| 113 |
|
|
| 114 |
|
//User roles |
| 115 |
|
if ($bigbluebuttonbn->participants == null || $bigbluebuttonbn->participants == '' || $bigbluebuttonbn->participants == '[]') { |
| 116 |
|
//The room that is being used comes from a previous version |
| 117 |
|
$moderator = has_capability('mod/bigbluebuttonbn:moderate', $context); |
| 118 |
|
} else { |
| 119 |
|
$moderator = bigbluebuttonbn_is_moderator($USER->id, get_user_roles($context, $USER->id, true), $bigbluebuttonbn->participants); |
| 120 |
|
} |
| 121 |
|
$administrator = has_capability('moodle/category:manage', $context); |
| 122 |
|
|
| 123 |
|
$can_moderate = ($administrator || $moderator); |