Completed
Push — master ( 58f2f2...86fc5a )
by Jesus
02:20
created
bbb_view.php 3 patches
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -22,8 +22,8 @@  discard block
 block discarded – undo
22 22
  * @license   http://www.gnu.org/copyleft/gpl.html GNU GPL v2 or later
23 23
  */
24 24
 
25
-require_once(dirname(dirname(dirname(__FILE__))).'/config.php');
26
-require_once(dirname(__FILE__).'/locallib.php');
25
+require_once(dirname(dirname(dirname(__FILE__))) . '/config.php');
26
+require_once(dirname(__FILE__) . '/locallib.php');
27 27
 
28 28
 $action = required_param('action', PARAM_TEXT);
29 29
 $id = optional_param('id', 0, PARAM_INT);
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
 
98 98
         // If user is not administrator nor moderator (user is steudent) and waiting is required.
99 99
         if (!$bbbsession['administrator'] && !$bbbsession['moderator'] && $bbbsession['wait']) {
100
-            header('Location: '.$bbbsession['logoutURL']);
100
+            header('Location: ' . $bbbsession['logoutURL']);
101 101
             break;
102 102
         }
103 103
 
@@ -113,17 +113,17 @@  discard block
 block discarded – undo
113 113
             // The server is unreachable.
114 114
             if ($bbbsession['administrator']) {
115 115
                 print_error('view_error_unable_join', 'bigbluebuttonbn',
116
-                    $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
116
+                    $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn');
117 117
                 break;
118 118
             }
119 119
             if ($bbbsession['moderator']) {
120 120
                 print_error('view_error_unable_join_teacher', 'bigbluebuttonbn',
121
-                    $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
121
+                    $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn');
122 122
                 break;
123 123
             }
124 124
 
125 125
             print_error('view_error_unable_join_student', 'bigbluebuttonbn',
126
-                $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
126
+                $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn');
127 127
             break;
128 128
         }
129 129
 
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
         // Moodle event logger: Create an event for meeting left.
159 159
         bigbluebuttonbn_event_log(BIGBLUEBUTTON_EVENT_RECORDING_VIEWED, $bigbluebuttonbn, $cm, ['other' => $rid]);
160 160
         // Execute the redirect.
161
-        header('Location: '.urldecode($href));
161
+        header('Location: ' . urldecode($href));
162 162
         break;
163 163
     default:
164 164
         bigbluebutton_bbb_view_close_window();
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
     }
202 202
     if ($durationtime > 0) {
203 203
         $data['duration'] = $durationtime;
204
-        $data['welcome'] .= '<br><br>'.str_replace('%duration%', ''.$durationtime, get_string('bbbdurationwarning', 'bigbluebuttonbn'));
204
+        $data['welcome'] .= '<br><br>' . str_replace('%duration%', '' . $durationtime, get_string('bbbdurationwarning', 'bigbluebuttonbn'));
205 205
     }
206 206
 
207 207
     $voicebridge = intval($bbbsession['voicebridge']);
@@ -247,7 +247,7 @@  discard block
 block discarded – undo
247 247
 
248 248
     if ($bbbsession['userlimit'] > 0 && intval($meetinginfo['participantCount']) >= $bbbsession['userlimit']) {
249 249
         // No more users allowed to join.
250
-        header('Location: '.$bbbsession['logoutURL']);
250
+        header('Location: ' . $bbbsession['logoutURL']);
251 251
         return;
252 252
     }
253 253
 
@@ -266,20 +266,20 @@  discard block
 block discarded – undo
266 266
     bigbluebuttonbn_participant_joined($bbbsession['meetingid'],
267 267
         ($bbbsession['administrator'] || $bbbsession['moderator']));
268 268
     // Execute the redirect.
269
-    header('Location: '.$joinurl);
269
+    header('Location: ' . $joinurl);
270 270
 }
271 271
 
272 272
 function bigbluebutton_bbb_view_errors($serrors, $id) {
273 273
     global $CFG, $OUTPUT;
274 274
 
275
-    $errors = (array) json_decode(urldecode($serrors));
275
+    $errors = (array)json_decode(urldecode($serrors));
276 276
     $msgerrors = '';
277 277
     foreach ($errors as $error) {
278
-        $msgerrors .= html_writer::tag('p', $error->{'message'}, array('class' => 'alert alert-danger'))."\n";
278
+        $msgerrors .= html_writer::tag('p', $error->{'message'}, array('class' => 'alert alert-danger')) . "\n";
279 279
     }
280 280
 
281 281
     echo $OUTPUT->header();
282 282
     print_error('view_error_bigbluebutton', 'bigbluebuttonbn',
283
-        $CFG->wwwroot.'/mod/bigbluebuttonbn/view.php?id='.$id, $msgerrors, $serrors);
283
+        $CFG->wwwroot . '/mod/bigbluebuttonbn/view.php?id=' . $id, $msgerrors, $serrors);
284 284
     echo $OUTPUT->footer();
285 285
 }
Please login to merge, or discard this patch.
Switch Indentation   +81 added lines, -81 removed lines patch added patch discarded remove patch
@@ -62,106 +62,106 @@
 block discarded – undo
62 62
 }
63 63
 
64 64
 switch (strtolower($action)) {
65
-    case 'logout':
66
-        if (isset($errors) && $errors != '') {
67
-            bigbluebutton_bbb_view_errors($errors, $id);
68
-            break;
69
-        }
65
+        case 'logout':
66
+            if (isset($errors) && $errors != '') {
67
+                bigbluebutton_bbb_view_errors($errors, $id);
68
+                break;
69
+            }
70 70
 
71
-        if (is_null($bbbsession)) {
72
-            bigbluebutton_bbb_view_close_window_manually();
73
-            break;
74
-        }
71
+            if (is_null($bbbsession)) {
72
+                bigbluebutton_bbb_view_close_window_manually();
73
+                break;
74
+            }
75 75
 
76
-        // Moodle event logger: Create an event for meeting left.
77
-        bigbluebuttonbn_event_log(BIGBLUEBUTTON_EVENT_MEETING_LEFT, $bigbluebuttonbn, $cm);
76
+            // Moodle event logger: Create an event for meeting left.
77
+            bigbluebuttonbn_event_log(BIGBLUEBUTTON_EVENT_MEETING_LEFT, $bigbluebuttonbn, $cm);
78 78
 
79
-        // Update the cache.
80
-        $meetinginfo = bigbluebuttonbn_get_meeting_info($bbbsession['meetingid'], BIGBLUEBUTTONBN_FORCED);
79
+            // Update the cache.
80
+            $meetinginfo = bigbluebuttonbn_get_meeting_info($bbbsession['meetingid'], BIGBLUEBUTTONBN_FORCED);
81 81
 
82
-        // Close the tab or window where BBB was opened.
83
-        bigbluebutton_bbb_view_close_window();
84
-        break;
85
-    case 'join':
86
-        if (is_null($bbbsession)) {
87
-            print_error('view_error_unable_join', 'bigbluebuttonbn');
82
+            // Close the tab or window where BBB was opened.
83
+            bigbluebutton_bbb_view_close_window();
88 84
             break;
89
-        }
85
+        case 'join':
86
+            if (is_null($bbbsession)) {
87
+                print_error('view_error_unable_join', 'bigbluebuttonbn');
88
+                break;
89
+            }
90 90
 
91
-        // See if the session is in progress.
92
-        if (bigbluebuttonbn_is_meeting_running($bbbsession['meetingid'])) {
93
-            // Since the meeting is already running, we just join the session.
94
-            bigbluebutton_bbb_view_join_meeting($bbbsession, $cm, $bigbluebuttonbn);
95
-            break;
96
-        }
91
+            // See if the session is in progress.
92
+            if (bigbluebuttonbn_is_meeting_running($bbbsession['meetingid'])) {
93
+                // Since the meeting is already running, we just join the session.
94
+                bigbluebutton_bbb_view_join_meeting($bbbsession, $cm, $bigbluebuttonbn);
95
+                break;
96
+            }
97 97
 
98
-        // If user is not administrator nor moderator (user is steudent) and waiting is required.
99
-        if (!$bbbsession['administrator'] && !$bbbsession['moderator'] && $bbbsession['wait']) {
100
-            header('Location: '.$bbbsession['logoutURL']);
101
-            break;
102
-        }
103
-
104
-        // As the meeting doesn't exist, try to create it.
105
-        $response = bigbluebuttonbn_get_create_meeting_array(
106
-            bigbluebutton_bbb_view_create_meeting_data($bbbsession, $bigbluebuttonbn),
107
-            bigbluebutton_bbb_view_create_meeting_metadata($bbbsession),
108
-            $bbbsession['presentation']['name'],
109
-            $bbbsession['presentation']['url']
110
-        );
111
-
112
-        if (!$response) {
113
-            // The server is unreachable.
114
-            if ($bbbsession['administrator']) {
115
-                print_error('view_error_unable_join', 'bigbluebuttonbn',
116
-                    $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
98
+            // If user is not administrator nor moderator (user is steudent) and waiting is required.
99
+            if (!$bbbsession['administrator'] && !$bbbsession['moderator'] && $bbbsession['wait']) {
100
+                header('Location: '.$bbbsession['logoutURL']);
117 101
                 break;
118 102
             }
119
-            if ($bbbsession['moderator']) {
120
-                print_error('view_error_unable_join_teacher', 'bigbluebuttonbn',
103
+
104
+            // As the meeting doesn't exist, try to create it.
105
+            $response = bigbluebuttonbn_get_create_meeting_array(
106
+                bigbluebutton_bbb_view_create_meeting_data($bbbsession, $bigbluebuttonbn),
107
+                bigbluebutton_bbb_view_create_meeting_metadata($bbbsession),
108
+                $bbbsession['presentation']['name'],
109
+                $bbbsession['presentation']['url']
110
+            );
111
+
112
+            if (!$response) {
113
+                // The server is unreachable.
114
+                if ($bbbsession['administrator']) {
115
+                    print_error('view_error_unable_join', 'bigbluebuttonbn',
116
+                        $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
117
+                    break;
118
+                }
119
+                if ($bbbsession['moderator']) {
120
+                    print_error('view_error_unable_join_teacher', 'bigbluebuttonbn',
121
+                        $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
122
+                    break;
123
+                }
124
+
125
+                print_error('view_error_unable_join_student', 'bigbluebuttonbn',
121 126
                     $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
122 127
                 break;
123 128
             }
124 129
 
125
-            print_error('view_error_unable_join_student', 'bigbluebuttonbn',
126
-                $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
127
-            break;
128
-        }
130
+            if ($response['returncode'] == 'FAILED') {
131
+                // The meeting was not created.
132
+                if (!$printerrorkey) {
133
+                    print_error($response['message'], 'bigbluebuttonbn');
134
+                    break;
135
+                }
136
+                $printerrorkey = bigbluebuttonbn_get_error_key($response['messageKey'], 'view_error_create');
137
+                print_error($printerrorkey, 'bigbluebuttonbn');
138
+                break;
139
+            }
129 140
 
130
-        if ($response['returncode'] == 'FAILED') {
131
-            // The meeting was not created.
132
-            if (!$printerrorkey) {
133
-                print_error($response['message'], 'bigbluebuttonbn');
141
+            if ($response['hasBeenForciblyEnded'] == 'true') {
142
+                print_error(get_string('index_error_forciblyended', 'bigbluebuttonbn'));
134 143
                 break;
135 144
             }
136
-            $printerrorkey = bigbluebuttonbn_get_error_key($response['messageKey'], 'view_error_create');
137
-            print_error($printerrorkey, 'bigbluebuttonbn');
138
-            break;
139
-        }
140 145
 
141
-        if ($response['hasBeenForciblyEnded'] == 'true') {
142
-            print_error(get_string('index_error_forciblyended', 'bigbluebuttonbn'));
146
+            // Moodle event logger: Create an event for meeting created.
147
+            bigbluebuttonbn_event_log(BIGBLUEBUTTON_EVENT_MEETING_CREATED, $bigbluebuttonbn, $cm);
148
+            // Internal logger: Insert a record with the meeting created.
149
+            bigbluebuttonbn_logs($bbbsession, BIGBLUEBUTTONBN_LOG_EVENT_CREATE);
150
+            // Since the meeting is already running, we just join the session.
151
+            bigbluebutton_bbb_view_join_meeting($bbbsession, $cm, $bigbluebuttonbn);
152
+            break;
153
+        case 'playback':
154
+            if ($href == '') {
155
+                bigbluebutton_bbb_view_close_window();
156
+                return;
157
+            }
158
+            // Moodle event logger: Create an event for meeting left.
159
+            bigbluebuttonbn_event_log(BIGBLUEBUTTON_EVENT_RECORDING_VIEWED, $bigbluebuttonbn, $cm, ['other' => $rid]);
160
+            // Execute the redirect.
161
+            header('Location: '.urldecode($href));
143 162
             break;
144
-        }
145
-
146
-        // Moodle event logger: Create an event for meeting created.
147
-        bigbluebuttonbn_event_log(BIGBLUEBUTTON_EVENT_MEETING_CREATED, $bigbluebuttonbn, $cm);
148
-        // Internal logger: Insert a record with the meeting created.
149
-        bigbluebuttonbn_logs($bbbsession, BIGBLUEBUTTONBN_LOG_EVENT_CREATE);
150
-        // Since the meeting is already running, we just join the session.
151
-        bigbluebutton_bbb_view_join_meeting($bbbsession, $cm, $bigbluebuttonbn);
152
-        break;
153
-    case 'playback':
154
-        if ($href == '') {
163
+        default:
155 164
             bigbluebutton_bbb_view_close_window();
156
-            return;
157
-        }
158
-        // Moodle event logger: Create an event for meeting left.
159
-        bigbluebuttonbn_event_log(BIGBLUEBUTTON_EVENT_RECORDING_VIEWED, $bigbluebuttonbn, $cm, ['other' => $rid]);
160
-        // Execute the redirect.
161
-        header('Location: '.urldecode($href));
162
-        break;
163
-    default:
164
-        bigbluebutton_bbb_view_close_window();
165 165
 }
166 166
 
167 167
 function bigbluebutton_bbb_view_close_window() {
Please login to merge, or discard this patch.
Indentation   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -178,10 +178,10 @@  discard block
 block discarded – undo
178 178
 
179 179
 function bigbluebutton_bbb_view_create_meeting_data(&$bbbsession, $bigbluebuttonbn) {
180 180
     $data = ['meetingID' => $bbbsession['meetingid'],
181
-              'name' => $bbbsession['meetingname'],
182
-              'attendeePW' => $bbbsession['viewerPW'],
183
-              'moderatorPW' => $bbbsession['modPW'],
184
-              'logoutURL' => $bbbsession['logoutURL'],
181
+                'name' => $bbbsession['meetingname'],
182
+                'attendeePW' => $bbbsession['viewerPW'],
183
+                'moderatorPW' => $bbbsession['modPW'],
184
+                'logoutURL' => $bbbsession['logoutURL'],
185 185
             ];
186 186
 
187 187
     $data['record'] = 'false';
@@ -219,14 +219,14 @@  discard block
 block discarded – undo
219 219
 
220 220
 function bigbluebutton_bbb_view_create_meeting_metadata(&$bbbsession) {
221 221
     $metadata = ['bbb-origin' => $bbbsession['origin'],
222
-                 'bbb-origin-version' => $bbbsession['originVersion'],
223
-                 'bbb-origin-server-name' => $bbbsession['originServerName'],
224
-                 'bbb-origin-server-common-name' => $bbbsession['originServerCommonName'],
225
-                 'bbb-origin-tag' => $bbbsession['originTag'],
226
-                 'bbb-context' => $bbbsession['course']->fullname,
227
-                 'bbb-recording-name' => $bbbsession['meetingname'],
228
-                 'bbb-recording-description' => bigbluebuttonbn_html2text($bbbsession['meetingdescription'], 64),
229
-                 'bbb-recording-tags' => bigbluebuttonbn_get_tags($bbbsession['cm']->id), // Same as $id.
222
+                    'bbb-origin-version' => $bbbsession['originVersion'],
223
+                    'bbb-origin-server-name' => $bbbsession['originServerName'],
224
+                    'bbb-origin-server-common-name' => $bbbsession['originServerCommonName'],
225
+                    'bbb-origin-tag' => $bbbsession['originTag'],
226
+                    'bbb-context' => $bbbsession['course']->fullname,
227
+                    'bbb-recording-name' => $bbbsession['meetingname'],
228
+                    'bbb-recording-description' => bigbluebuttonbn_html2text($bbbsession['meetingdescription'], 64),
229
+                    'bbb-recording-tags' => bigbluebuttonbn_get_tags($bbbsession['cm']->id), // Same as $id.
230 230
                 ];
231 231
 
232 232
     if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recordingstatus_enabled')) {
@@ -234,8 +234,8 @@  discard block
 block discarded – undo
234 234
             array(
235 235
                 'email' => bigbluebuttonbn_get_moderator_email($bbbsession['context']),
236 236
                 'context' => $bbbsession['bigbluebuttonbnURL']
237
-              )
238
-          );
237
+                )
238
+            );
239 239
     }
240 240
     if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recordingready_enabled')) {
241 241
         $metadata['bn-recording-ready-url'] = $bbbsession['recordingReadyURL'];
Please login to merge, or discard this patch.
mod_form.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -111,7 +111,7 @@  discard block
 block discarded – undo
111 111
                 'alt' => get_string('delete'),
112 112
                 'title' => get_string('delete'),
113 113
                 'src' => $jsvars['pix_icon_delete']
114
-              );
114
+                );
115 115
 
116 116
             $jsvars['pix_icon_delete'] = html_writer::tag('img', $options);
117 117
         }
@@ -211,8 +211,8 @@  discard block
 block discarded – undo
211 211
             $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'],
212 212
                 $field['description_key'], 0, ['maxlength' => 4, 'size' => 6],
213 213
                 ['message' => get_string('mod_form_field_voicebridge_format_error', 'bigbluebuttonbn'),
214
-                 'type' => 'numeric', 'rule' => '####', 'validator' => 'server']
215
-              );
214
+                    'type' => 'numeric', 'rule' => '####', 'validator' => 'server']
215
+                );
216 216
         } else {
217 217
             $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'],
218 218
                 $field['description_key'], 0, ['maxlength' => 4, 'size' => 6]);
@@ -254,7 +254,7 @@  discard block
 block discarded – undo
254 254
             $field['description_key'], $cfg['recordings_html_default']);
255 255
 
256 256
         $field = ['type' => 'hidden', 'name' => 'recordings_deleted_activities', 'data_type' => PARAM_INT,
257
-                  'description_key' => null];
257
+                    'description_key' => null];
258 258
         if ($cfg['recordings_deleted_activities_editable']) {
259 259
             $field['type'] = 'checkbox';
260 260
             $field['description_key'] = 'mod_form_field_recordings_deleted_activities';
@@ -309,7 +309,7 @@  discard block
 block discarded – undo
309 309
             html_writer::select($participantselection['type_options'], 'bigbluebuttonbn_participant_selection_type',
310 310
                 $participantselection['type_selected'], array(),
311 311
                 array('id' => 'bigbluebuttonbn_participant_selection_type',
312
-                      'onchange' => 'M.mod_bigbluebuttonbn.modform.participant_selection_set(); return 0;')).'&nbsp;&nbsp;'.
312
+                        'onchange' => 'M.mod_bigbluebuttonbn.modform.participant_selection_set(); return 0;')).'&nbsp;&nbsp;'.
313 313
             html_writer::select($participantselection['options'], 'bigbluebuttonbn_participant_selection',
314 314
                 $participantselection['selected'], array(),
315 315
                 array('id' => 'bigbluebuttonbn_participant_selection', 'disabled' => 'disabled')).'&nbsp;&nbsp;'.
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -26,8 +26,8 @@  discard block
 block discarded – undo
26 26
 
27 27
 defined('MOODLE_INTERNAL') || die();
28 28
 
29
-require_once(dirname(__FILE__).'/locallib.php');
30
-require_once($CFG->dirroot.'/course/moodleform_mod.php');
29
+require_once(dirname(__FILE__) . '/locallib.php');
30
+require_once($CFG->dirroot . '/course/moodleform_mod.php');
31 31
 
32 32
 class mod_bigbluebuttonbn_mod_form extends moodleform_mod {
33 33
 
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
         $serverversion = bigbluebuttonbn_get_server_version();
39 39
         if (is_null($serverversion)) {
40 40
             print_error('general_error_unable_connect', 'bigbluebuttonbn',
41
-                $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn');
41
+                $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn');
42 42
         }
43 43
 
44 44
         $bigbluebuttonbn = null;
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
                 );
130 130
                 $defaultvalues['presentation'] = $draftitemid;
131 131
             } catch (Exception $e) {
132
-                debugging('Presentation could not be loaded: '.$e->getMessage(), DEBUG_DEVELOPER);
132
+                debugging('Presentation could not be loaded: ' . $e->getMessage(), DEBUG_DEVELOPER);
133 133
                 return null;
134 134
             }
135 135
         }
@@ -309,10 +309,10 @@  discard block
 block discarded – undo
309 309
             html_writer::select($participantselection['type_options'], 'bigbluebuttonbn_participant_selection_type',
310 310
                 $participantselection['type_selected'], array(),
311 311
                 array('id' => 'bigbluebuttonbn_participant_selection_type',
312
-                      'onchange' => 'M.mod_bigbluebuttonbn.modform.participant_selection_set(); return 0;')).'&nbsp;&nbsp;'.
312
+                      'onchange' => 'M.mod_bigbluebuttonbn.modform.participant_selection_set(); return 0;')) . '&nbsp;&nbsp;' .
313 313
             html_writer::select($participantselection['options'], 'bigbluebuttonbn_participant_selection',
314 314
                 $participantselection['selected'], array(),
315
-                array('id' => 'bigbluebuttonbn_participant_selection', 'disabled' => 'disabled')).'&nbsp;&nbsp;'.
315
+                array('id' => 'bigbluebuttonbn_participant_selection', 'disabled' => 'disabled')) . '&nbsp;&nbsp;' .
316 316
             html_writer::tag('input', '', array('id' => 'id_addselectionid', 'type' => 'button', 'class' => 'btn btn-secondary',
317 317
                 'value' => get_string('mod_form_field_participant_list_action_add', 'bigbluebuttonbn'),
318 318
                 'onclick' => 'M.mod_bigbluebuttonbn.modform.participant_add(); return 0;'
@@ -332,7 +332,7 @@  discard block
 block discarded – undo
332 332
         // Render elements for participant list.
333 333
         $htmllist = html_writer::tag('div',
334 334
             html_writer::label(get_string('mod_form_field_participant_list', 'bigbluebuttonbn'),
335
-                'bigbluebuttonbn_participant_list').
335
+                'bigbluebuttonbn_participant_list') .
336 336
             html_writer::table($table)
337 337
         );
338 338
 
@@ -365,7 +365,7 @@  discard block
 block discarded – undo
365 365
         }
366 366
 
367 367
         $mform->addElement($type, $name, get_string($descriptionkey, 'bigbluebuttonbn'), $options);
368
-        if (get_string_manager()->string_exists($descriptionkey.'_help', 'bigbluebuttonbn')) {
368
+        if (get_string_manager()->string_exists($descriptionkey . '_help', 'bigbluebuttonbn')) {
369 369
             $mform->addHelpButton($name, $descriptionkey, 'bigbluebuttonbn');
370 370
         }
371 371
         if (!empty($rule)) {
Please login to merge, or discard this patch.
bbb_broker.php 2 patches
Indentation   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -413,10 +413,10 @@  discard block
 block discarded – undo
413 413
     if (bigbluebuttonbn_broker_recording_is_imported($recordings, $params['id'])) {
414 414
         // Execute unpublish or protect on imported recording link.
415 415
         return array(
416
-          'status' => bigbluebuttonbn_publish_recording_imported(
417
-              $params['id'], $bbbsession['bigbluebuttonbn']->id, false
416
+            'status' => bigbluebuttonbn_publish_recording_imported(
417
+                $params['id'], $bbbsession['bigbluebuttonbn']->id, false
418 418
             )
419
-          );
419
+            );
420 420
     }
421 421
 
422 422
     // As the recordingid was not identified as imported recording link, execute unpublish on a real recording.
@@ -436,26 +436,26 @@  discard block
 block discarded – undo
436 436
     }
437 437
     // Second: Execute the real unpublish.
438 438
     return array(
439
-      'status' => bigbluebuttonbn_publish_recordings($params['id'], 'false')
440
-      );
439
+        'status' => bigbluebuttonbn_publish_recordings($params['id'], 'false')
440
+        );
441 441
 }
442 442
 
443 443
 function bigbluebuttonbn_broker_recording_action_edit($bbbsession, $params, $recordings) {
444 444
     if (bigbluebuttonbn_broker_recording_is_imported($recordings, $params['id'])) {
445 445
         // Execute update on imported recording link.
446 446
         return array(
447
-          'status' => bigbluebuttonbn_update_recording_imported(
448
-              $params['id'], $bbbsession['bigbluebuttonbn']->id, json_decode($params['meta'], true)
447
+            'status' => bigbluebuttonbn_update_recording_imported(
448
+                $params['id'], $bbbsession['bigbluebuttonbn']->id, json_decode($params['meta'], true)
449 449
             )
450
-          );
450
+            );
451 451
     }
452 452
 
453 453
     // As the recordingid was not identified as imported recording link, execute update on a real recording.
454 454
     // (No need to update imported links as the update only affects the actual recording).
455 455
     // Execute update on actual recording.
456 456
     return array(
457
-      'status' => bigbluebuttonbn_update_recordings($params['id'], json_decode($params['meta']))
458
-      );
457
+        'status' => bigbluebuttonbn_update_recordings($params['id'], json_decode($params['meta']))
458
+        );
459 459
 }
460 460
 
461 461
 function bigbluebuttonbn_broker_recording_action_delete($bbbsession, $params, $recordings) {
@@ -464,10 +464,10 @@  discard block
 block discarded – undo
464 464
     if (bigbluebuttonbn_broker_recording_is_imported($recordings, $params['id'])) {
465 465
         // Execute delete on imported recording link.
466 466
         return array(
467
-          'status' => bigbluebuttonbn_delete_recording_imported(
468
-              $params['id'], $bbbsession['bigbluebuttonbn']->id
467
+            'status' => bigbluebuttonbn_delete_recording_imported(
468
+                $params['id'], $bbbsession['bigbluebuttonbn']->id
469 469
             )
470
-          );
470
+            );
471 471
     }
472 472
 
473 473
     // As the recordingid was not identified as imported recording link, execute delete on a real recording.
@@ -482,8 +482,8 @@  discard block
 block discarded – undo
482 482
     }
483 483
     // Execute the actual delete.
484 484
     return array(
485
-      'status' => bigbluebuttonbn_delete_recordings($params['id'])
486
-      );
485
+        'status' => bigbluebuttonbn_delete_recordings($params['id'])
486
+        );
487 487
 }
488 488
 
489 489
 function bigbluebuttonbn_broker_recording_ready($params, $bigbluebuttonbn) {
@@ -624,10 +624,10 @@  discard block
 block discarded – undo
624 624
     $params['recording_import'] = ['id' => 'The recordingID must be specified.'];
625 625
     $params['recording_ready'] = [
626 626
             'signed_parameters' => 'A JWT encoded string must be included as [signed_parameters].'
627
-          ];
627
+            ];
628 628
     $params['live_session_events'] = [
629 629
             'signed_parameters' => 'A JWT encoded string must be included as [signed_parameters].'
630
-          ];
630
+            ];
631 631
     return $params;
632 632
 }
633 633
 
Please login to merge, or discard this patch.
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -22,8 +22,8 @@  discard block
 block discarded – undo
22 22
  * @license   http://www.gnu.org/copyleft/gpl.html GNU GPL v2 or later
23 23
  */
24 24
 
25
-require_once(dirname(dirname(dirname(__FILE__))).'/config.php');
26
-require_once(dirname(__FILE__).'/locallib.php');
25
+require_once(dirname(dirname(dirname(__FILE__))) . '/config.php');
26
+require_once(dirname(__FILE__) . '/locallib.php');
27 27
 
28 28
 use \Firebase\JWT\JWT;
29 29
 
@@ -39,13 +39,13 @@  discard block
 block discarded – undo
39 39
 $params['meta'] = optional_param('meta', '', PARAM_TEXT);
40 40
 
41 41
 if (empty($params['action'])) {
42
-    header('HTTP/1.0 400 Bad Request. Parameter ['.$params['action'].'] was not included');
42
+    header('HTTP/1.0 400 Bad Request. Parameter [' . $params['action'] . '] was not included');
43 43
     return;
44 44
 }
45 45
 
46 46
 $error = bigbluebuttonbn_broker_validate_parameters($params);
47 47
 if (!empty($error)) {
48
-    header('HTTP/1.0 400 Bad Request. '.$error);
48
+    header('HTTP/1.0 400 Bad Request. ' . $error);
49 49
     return;
50 50
 }
51 51
 
@@ -139,11 +139,11 @@  discard block
 block discarded – undo
139 139
         return;
140 140
     }
141 141
 
142
-    header('HTTP/1.0 400 Bad request. The action '. $a . ' doesn\'t exist');
142
+    header('HTTP/1.0 400 Bad request. The action ' . $a . ' doesn\'t exist');
143 143
     return;
144 144
 
145 145
 } catch (Exception $e) {
146
-    header('HTTP/1.0 500 Internal Server Error. '.$e->getMessage());
146
+    header('HTTP/1.0 500 Internal Server Error. ' . $e->getMessage());
147 147
     return;
148 148
 }
149 149
 
@@ -289,7 +289,7 @@  discard block
 block discarded – undo
289 289
 
290 290
 function bigbluebuttonbn_broker_recording_info_current($recording, $params) {
291 291
     $callbackresponse['status'] = true;
292
-    $callbackresponse['published'] = (string) $recording['published'];
292
+    $callbackresponse['published'] = (string)$recording['published'];
293 293
     if (!isset($params['meta'])) {
294 294
         return $callbackresponse;
295 295
     }
@@ -382,7 +382,7 @@  discard block
 block discarded – undo
382 382
         // Execute publish or unprotect on imported recording link, if the real recording is published.
383 383
         $realrecordings = bigbluebuttonbn_get_recordings_array(
384 384
             $recordings[$params['id']]['meetingID'], $recordings[$params['id']]['recordID']);
385
-        $status = ($realrecordings[$params['id']][$action.'ed'] === 'true');
385
+        $status = ($realrecordings[$params['id']][$action . 'ed'] === 'true');
386 386
         if ($status) {
387 387
             // Only if the physical recording is published, execute publish on imported recording link.
388 388
             bigbluebuttonbn_publish_recording_imported($params['id'], $bbbsession['bigbluebuttonbn']->id, true);
@@ -394,7 +394,7 @@  discard block
 block discarded – undo
394 394
 
395 395
     $response = array('status' => $status);
396 396
     if (!$status) {
397
-        $response['message'] = get_string('view_recording_'.$action.'_link_error', 'bigbluebuttonbn');
397
+        $response['message'] = get_string('view_recording_' . $action . '_link_error', 'bigbluebuttonbn');
398 398
     }
399 399
     return $response;
400 400
 }
@@ -427,7 +427,7 @@  discard block
 block discarded – undo
427 427
         foreach ($importedall as $key => $record) {
428 428
             $meta = json_decode($record->meta, true);
429 429
             // Prepare data for the update.
430
-            $meta['recording'][$action.'ed'] = 'false';
430
+            $meta['recording'][$action . 'ed'] = 'false';
431 431
             $importedall[$key]->meta = json_encode($meta);
432 432
 
433 433
             // Proceed with the update.
@@ -493,8 +493,8 @@  discard block
 block discarded – undo
493 493
         $decodedparameters = JWT::decode($params['signed_parameters'], \mod_bigbluebuttonbn\locallib\config::get('shared_secret'),
494 494
             array('HS256'));
495 495
     } catch (Exception $e) {
496
-        $error = 'Caught exception: '.$e->getMessage();
497
-        header('HTTP/1.0 400 Bad Request. '.$error);
496
+        $error = 'Caught exception: ' . $e->getMessage();
497
+        header('HTTP/1.0 400 Bad Request. ' . $error);
498 498
         return;
499 499
     }
500 500
 
@@ -512,8 +512,8 @@  discard block
 block discarded – undo
512 512
         bigbluebuttonbn_send_notification_recording_ready($bigbluebuttonbn);
513 513
         header('HTTP/1.0 202 Accepted');
514 514
     } catch (Exception $e) {
515
-        $error = 'Caught exception: '.$e->getMessage();
516
-        header('HTTP/1.0 503 Service Unavailable. '.$error);
515
+        $error = 'Caught exception: ' . $e->getMessage();
516
+        header('HTTP/1.0 503 Service Unavailable. ' . $error);
517 517
     }
518 518
 }
519 519
 
@@ -528,7 +528,7 @@  discard block
 block discarded – undo
528 528
     $importrecordings = $SESSION->bigbluebuttonbn_importrecordings;
529 529
     if (!isset($importrecordings[$params['id']])) {
530 530
         $error = "Recording {$params['id']} could not be found. It can not be imported";
531
-        header('HTTP/1.0 404 Not found. '.$error);
531
+        header('HTTP/1.0 404 Not found. ' . $error);
532 532
         return;
533 533
     }
534 534
 
@@ -536,7 +536,7 @@  discard block
 block discarded – undo
536 536
 
537 537
     $importrecordings[$params['id']]['imported'] = true;
538 538
     $overrides = array('meetingid' => $importrecordings[$params['id']]['meetingID']);
539
-    $meta = '{"recording":'.json_encode($importrecordings[$params['id']]).'}';
539
+    $meta = '{"recording":' . json_encode($importrecordings[$params['id']]) . '}';
540 540
     bigbluebuttonbn_logs($bbbsession, BIGBLUEBUTTONBN_LOG_EVENT_IMPORT, $overrides, $meta);
541 541
     // Moodle event logger: Create an event for recording imported.
542 542
     if (isset($bbbsession['bigbluebutton']) && isset($bbbsession['cm'])) {
@@ -554,8 +554,8 @@  discard block
 block discarded – undo
554 554
         $decodedparameters = JWT::decode($params['signed_parameters'], \mod_bigbluebuttonbn\locallib\config::get('shared_secret'),
555 555
             array('HS256'));
556 556
     } catch (Exception $e) {
557
-        $error = 'Caught exception: '.$e->getMessage();
558
-        header('HTTP/1.0 400 Bad Request. '.$error);
557
+        $error = 'Caught exception: ' . $e->getMessage();
558
+        header('HTTP/1.0 400 Bad Request. ' . $error);
559 559
         return;
560 560
     }
561 561
 
@@ -593,7 +593,7 @@  discard block
 block discarded – undo
593 593
 
594 594
     $action = strtolower($params['action']);
595 595
     if (!array_key_exists($action, $requiredparams)) {
596
-        return 'Action '.$params['action'].' can not be performed.';
596
+        return 'Action ' . $params['action'] . ' can not be performed.';
597 597
     }
598 598
 
599 599
     return bigbluebuttonbn_broker_validate_parameters_message($params, $requiredparams[$action]);
Please login to merge, or discard this patch.
locallib.php 2 patches
Indentation   +48 added lines, -48 removed lines patch added patch discarded remove patch
@@ -85,9 +85,9 @@  discard block
 block discarded – undo
85 85
 // BigBlueButton API Calls.
86 86
 function bigbluebuttonbn_get_join_url($meetingid, $username, $pw, $logouturl, $configtoken = null, $userid = null) {
87 87
     $data = ['meetingID' => $meetingid,
88
-              'fullName' => $username,
89
-              'password' => $pw,
90
-              'logoutURL' => $logouturl,
88
+                'fullName' => $username,
89
+                'password' => $pw,
90
+                'logoutURL' => $logouturl,
91 91
             ];
92 92
 
93 93
     if (!is_null($configtoken)) {
@@ -188,24 +188,24 @@  discard block
 block discarded – undo
188 188
 function bigbluebuttonbn_get_meeting_info_array($meetingid) {
189 189
     $xml = bigbluebuttonbn_wrap_xml_load_file(
190 190
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid])
191
-      );
191
+        );
192 192
 
193 193
     if ($xml && $xml->returncode == 'SUCCESS' && empty($xml->messageKey)) {
194 194
         // Meeting info was returned.
195 195
         return array('returncode' => $xml->returncode,
196
-                     'meetingID' => $xml->meetingID,
197
-                     'moderatorPW' => $xml->moderatorPW,
198
-                     'attendeePW' => $xml->attendeePW,
199
-                     'hasBeenForciblyEnded' => $xml->hasBeenForciblyEnded,
200
-                     'running' => $xml->running,
201
-                     'recording' => $xml->recording,
202
-                     'startTime' => $xml->startTime,
203
-                     'endTime' => $xml->endTime,
204
-                     'participantCount' => $xml->participantCount,
205
-                     'moderatorCount' => $xml->moderatorCount,
206
-                     'attendees' => $xml->attendees,
207
-                     'metadata' => $xml->metadata,
208
-                   );
196
+                        'meetingID' => $xml->meetingID,
197
+                        'moderatorPW' => $xml->moderatorPW,
198
+                        'attendeePW' => $xml->attendeePW,
199
+                        'hasBeenForciblyEnded' => $xml->hasBeenForciblyEnded,
200
+                        'running' => $xml->running,
201
+                        'recording' => $xml->recording,
202
+                        'startTime' => $xml->startTime,
203
+                        'endTime' => $xml->endTime,
204
+                        'participantCount' => $xml->participantCount,
205
+                        'moderatorCount' => $xml->moderatorCount,
206
+                        'attendees' => $xml->attendees,
207
+                        'metadata' => $xml->metadata,
208
+                    );
209 209
     }
210 210
 
211 211
     if ($xml) {
@@ -269,7 +269,7 @@  discard block
 block discarded – undo
269 269
         // Do getRecordings is executed using a method GET (supported by all versions of BBB).
270 270
         $xml = bigbluebuttonbn_wrap_xml_load_file(
271 271
             \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getRecordings', ['meetingID' => implode(',', $mids)])
272
-          );
272
+            );
273 273
         if ($xml && $xml->returncode == 'SUCCESS' && isset($xml->recordings)) {
274 274
             // If there were meetings already created.
275 275
             foreach ($xml->recordings->recording as $recording) {
@@ -332,7 +332,7 @@  discard block
 block discarded – undo
332 332
 function bigbluebuttonbn_get_default_config_xml() {
333 333
     $xml = bigbluebuttonbn_wrap_xml_load_file(
334 334
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getDefaultConfigXML')
335
-      );
335
+        );
336 336
 
337 337
     return $xml;
338 338
 }
@@ -406,7 +406,7 @@  discard block
 block discarded – undo
406 406
     foreach ($ids as $id) {
407 407
         $xml = bigbluebuttonbn_wrap_xml_load_file(
408 408
             \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('deleteRecordings', ['recordID' => $id])
409
-          );
409
+            );
410 410
         if ($xml && $xml->returncode != 'SUCCESS') {
411 411
             return false;
412 412
         }
@@ -424,7 +424,7 @@  discard block
 block discarded – undo
424 424
     foreach ($ids as $id) {
425 425
         $xml = bigbluebuttonbn_wrap_xml_load_file(
426 426
             \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('publishRecordings', ['recordID' => $id, 'publish' => $publish])
427
-          );
427
+            );
428 428
         if ($xml && $xml->returncode != 'SUCCESS') {
429 429
             return false;
430 430
         }
@@ -442,7 +442,7 @@  discard block
 block discarded – undo
442 442
     foreach ($ids as $id) {
443 443
         $xml = bigbluebuttonbn_wrap_xml_load_file(
444 444
             \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('updateRecordings', ['recordID' => $id] + (array) $params)
445
-          );
445
+            );
446 446
         if ($xml && $xml->returncode != 'SUCCESS') {
447 447
             return false;
448 448
         }
@@ -501,7 +501,7 @@  discard block
 block discarded – undo
501 501
 function bigbluebuttonbn_end_meeting($meetingid, $modpw) {
502 502
     $xml = bigbluebuttonbn_wrap_xml_load_file(
503 503
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('end', ['meetingID' => $meetingid, 'password' => $modpw])
504
-      );
504
+        );
505 505
 
506 506
     if ($xml) {
507 507
         // If the xml packet returned failure it displays the message to the user.
@@ -518,7 +518,7 @@  discard block
 block discarded – undo
518 518
 function bigbluebuttonbn_is_meeting_running($meetingid) {
519 519
     $xml = bigbluebuttonbn_wrap_xml_load_file(
520 520
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('isMeetingRunning', ['meetingID' => $meetingid])
521
-      );
521
+        );
522 522
 
523 523
     if ($xml && $xml->returncode == 'SUCCESS') {
524 524
         return ($xml->running == 'true');
@@ -530,7 +530,7 @@  discard block
 block discarded – undo
530 530
 function bigbluebuttonbn_get_server_version() {
531 531
     $xml = bigbluebuttonbn_wrap_xml_load_file(
532 532
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url()
533
-      );
533
+        );
534 534
 
535 535
     if ($xml && $xml->returncode == 'SUCCESS') {
536 536
         return $xml->version;
@@ -591,10 +591,10 @@  discard block
 block discarded – undo
591 591
 
592 592
         $options = array();
593 593
         $options['CURLOPT_HTTPHEADER'] = array(
594
-                 'Content-Type: '.$contenttype,
595
-                 'Content-Length: '.strlen($data),
596
-                 'Content-Language: en-US',
597
-               );
594
+                    'Content-Type: '.$contenttype,
595
+                    'Content-Length: '.strlen($data),
596
+                    'Content-Language: en-US',
597
+                );
598 598
 
599 599
         return $c->post($url, $data, $options);
600 600
     }
@@ -673,18 +673,18 @@  discard block
 block discarded – undo
673 673
         'all' => array(
674 674
             'name' => get_string('mod_form_field_participant_list_type_all', 'bigbluebuttonbn'),
675 675
             'children' => []
676
-          )
677
-      );
676
+            )
677
+        );
678 678
 
679 679
     $data['role'] = array(
680 680
         'name' => get_string('mod_form_field_participant_list_type_role', 'bigbluebuttonbn'),
681 681
         'children' => bigbluebuttonbn_get_roles_select($context)
682
-      );
682
+        );
683 683
 
684 684
     $data['user'] = array(
685 685
         'name' => get_string('mod_form_field_participant_list_type_user', 'bigbluebuttonbn'),
686 686
         'children' => bigbluebuttonbn_get_users_select($context)
687
-      );
687
+        );
688 688
 
689 689
     return $data;
690 690
 }
@@ -731,9 +731,9 @@  discard block
 block discarded – undo
731 731
         }
732 732
 
733 733
         $participantlistarray[] = array(
734
-              'selectiontype' => 'role',
735
-              'selectionid' => $moderatordefault,
736
-              'role' => BIGBLUEBUTTONBN_ROLE_MODERATOR);
734
+                'selectiontype' => 'role',
735
+                'selectionid' => $moderatordefault,
736
+                'role' => BIGBLUEBUTTONBN_ROLE_MODERATOR);
737 737
     }
738 738
 
739 739
     return $participantlistarray;
@@ -745,11 +745,11 @@  discard block
 block discarded – undo
745 745
             'all' => get_string('mod_form_field_participant_list_type_all', 'bigbluebuttonbn'),
746 746
             'role' => get_string('mod_form_field_participant_list_type_role', 'bigbluebuttonbn'),
747 747
             'user' => get_string('mod_form_field_participant_list_type_user', 'bigbluebuttonbn'),
748
-          ],
748
+            ],
749 749
         'type_selected' => 'all',
750 750
         'options' => ['all' => '---------------'],
751 751
         'selected' => 'all',
752
-      ];
752
+        ];
753 753
 }
754 754
 
755 755
 function bigbluebuttonbn_is_moderator($context, $participants, $userid = null, $userroles = null) {
@@ -880,8 +880,8 @@  discard block
 block discarded – undo
880 880
     }
881 881
 
882 882
     $parray = array('url' => $purl, 'name' => $pname,
883
-                               'icon' => $picon,
884
-                               'mimetype_description' => $pmimetypedescrip);
883
+                                'icon' => $picon,
884
+                                'mimetype_description' => $pmimetypedescrip);
885 885
 
886 886
     return $parray;
887 887
 }
@@ -961,7 +961,7 @@  discard block
 block discarded – undo
961 961
     }
962 962
 
963 963
     $event = call_user_func_array('\mod_bigbluebuttonbn\event\bigbluebuttonbn_'.$eventtype.'::create',
964
-      array($eventproperties));
964
+        array($eventproperties));
965 965
     $event->trigger();
966 966
 }
967 967
 
@@ -1009,7 +1009,7 @@  discard block
 block discarded – undo
1009 1009
     // Ping again and refresh the cache.
1010 1010
     $meetinginfo = (array) bigbluebuttonbn_wrap_xml_load_file(
1011 1011
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid])
1012
-      );
1012
+        );
1013 1013
     $cache->set($meetingid, array('creation_time' => time(), 'meeting_info' => json_encode($meetinginfo)));
1014 1014
 
1015 1015
     return $meetinginfo;
@@ -1150,7 +1150,7 @@  discard block
 block discarded – undo
1150 1150
         $actionbar .= bigbluebuttonbn_actionbar_render_button(
1151 1151
             $recording,
1152 1152
             bigbluebuttonbn_get_recording_data_row_actionbar_payload($recording, $tool)
1153
-          );
1153
+            );
1154 1154
     }
1155 1155
     $head = html_writer::start_tag('div', array(
1156 1156
         'id' => 'recording-actionbar-' . $recording['recordID'],
@@ -1233,8 +1233,8 @@  discard block
 block discarded – undo
1233 1233
 
1234 1234
     $id = 'playbacks-'.$recording['recordID'];
1235 1235
     $recordingtypes = html_writer::start_tag('div', array('id' => $id, 'data-imported' => $dataimported,
1236
-          'data-recordingid' => $recording['recordID'], 'data-meetingid' => $recording['meetingID'],
1237
-          'title' => $title, $visibility => $visibility));
1236
+            'data-recordingid' => $recording['recordID'], 'data-meetingid' => $recording['meetingID'],
1237
+            'title' => $title, $visibility => $visibility));
1238 1238
     foreach ($recording['playbacks'] as $playback) {
1239 1239
         $onclick = 'M.mod_bigbluebuttonbn.recordings.recording_play(this);';
1240 1240
         $href = $CFG->wwwroot.'/mod/bigbluebuttonbn/bbb_view.php?action=playback&bn='.$bigbluebuttonbnid.
@@ -1340,7 +1340,7 @@  discard block
 block discarded – undo
1340 1340
             'onclick' => $onclick,
1341 1341
             'data-action' => $data['action'],
1342 1342
             'data-links' => bigbluebuttonbn_get_count_recording_imported_instances($recording['recordID'])
1343
-          );
1343
+            );
1344 1344
         return $OUTPUT->action_icon('#', $icon, null, $linkattributes, false);
1345 1345
     }
1346 1346
 
@@ -1679,8 +1679,8 @@  discard block
 block discarded – undo
1679 1679
     $activitytime = '';
1680 1680
     if ($time) {
1681 1681
         $activitytime = calendar_day_representation($time).' '.
1682
-          get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn').' '.
1683
-          calendar_time_representation($time);
1682
+            get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn').' '.
1683
+            calendar_time_representation($time);
1684 1684
     }
1685 1685
 
1686 1686
     return $activitytime;
Please login to merge, or discard this patch.
Spacing   +102 added lines, -102 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 
28 28
 global $CFG;
29 29
 
30
-require_once(dirname(__FILE__).'/lib.php');
30
+require_once(dirname(__FILE__) . '/lib.php');
31 31
 
32 32
 const BIGBLUEBUTTONBN_FORCED = true;
33 33
 
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
     if (isset($meta)) {
77 77
         $log->meta = $meta;
78 78
     } else if ($event == BIGBLUEBUTTONBN_LOG_EVENT_CREATE) {
79
-        $log->meta = '{"record":'.($bbbsession['record'] ? 'true' : 'false').'}';
79
+        $log->meta = '{"record":' . ($bbbsession['record'] ? 'true' : 'false') . '}';
80 80
     }
81 81
 
82 82
     $DB->insert_record('bigbluebuttonbn_logs', $log);
@@ -121,8 +121,8 @@  discard block
 block discarded – undo
121 121
 
122 122
     if (!is_null($pname) && !is_null($purl)) {
123 123
         $method = BIGBLUEBUTTONBN_METHOD_POST;
124
-        $data = "<?xml version='1.0' encoding='UTF-8'?><modules><module name='" . $pname . "'><document url='".
125
-            $purl."' /></module></modules>";
124
+        $data = "<?xml version='1.0' encoding='UTF-8'?><modules><module name='" . $pname . "'><document url='" .
125
+            $purl . "' /></module></modules>";
126 126
     }
127 127
 
128 128
     $xml = bigbluebuttonbn_wrap_xml_load_file($createmeetingurl, $method, $data);
@@ -167,7 +167,7 @@  discard block
 block discarded – undo
167 167
                                 'moderatorPW' => $meeting->moderatorPW,
168 168
                                 'attendeePW' => $meeting->attendeePW,
169 169
                                 'hasBeenForciblyEnded' => $meeting->hasBeenForciblyEnded,
170
-                                'running' => $meeting->running, );
170
+                                'running' => $meeting->running,);
171 171
         }
172 172
 
173 173
         return $meetings;
@@ -308,12 +308,12 @@  discard block
 block discarded – undo
308 308
 function bigbluebuttonbn_get_recordings_imported_array($courseid, $bigbluebuttonbnid = null, $subset = true) {
309 309
     global $DB;
310 310
 
311
-    $select = "courseid = '{$courseid}' AND bigbluebuttonbnid <> '{$bigbluebuttonbnid}' AND log = '".
312
-        BIGBLUEBUTTONBN_LOG_EVENT_IMPORT."'";
311
+    $select = "courseid = '{$courseid}' AND bigbluebuttonbnid <> '{$bigbluebuttonbnid}' AND log = '" .
312
+        BIGBLUEBUTTONBN_LOG_EVENT_IMPORT . "'";
313 313
     if ($bigbluebuttonbnid === null) {
314
-        $select = "courseid = '{$courseid}' AND log = '".BIGBLUEBUTTONBN_LOG_EVENT_IMPORT."'";
314
+        $select = "courseid = '{$courseid}' AND log = '" . BIGBLUEBUTTONBN_LOG_EVENT_IMPORT . "'";
315 315
     } else if ($subset) {
316
-        $select = "bigbluebuttonbnid = '{$bigbluebuttonbnid}' AND log = '".BIGBLUEBUTTONBN_LOG_EVENT_IMPORT."'";
316
+        $select = "bigbluebuttonbnid = '{$bigbluebuttonbnid}' AND log = '" . BIGBLUEBUTTONBN_LOG_EVENT_IMPORT . "'";
317 317
     }
318 318
     $recordsimported = $DB->get_records_select('bigbluebuttonbn_logs', $select);
319 319
 
@@ -340,37 +340,37 @@  discard block
 block discarded – undo
340 340
 function bigbluebuttonbn_get_default_config_xml_array() {
341 341
     $defaultconfigxml = bigbluebuttonbn_getDefaultConfigXML();
342 342
 
343
-    return (array) $defaultconfigxml;
343
+    return (array)$defaultconfigxml;
344 344
 }
345 345
 
346 346
 function bigbluebuttonbn_get_recording_array_value($recording) {
347 347
     // Add formats.
348 348
     $playbackarray = array();
349 349
     foreach ($recording->playback->format as $format) {
350
-        $playbackarray[(string) $format->type] = array('type' => (string) $format->type,
351
-            'url' => (string) $format->url, 'length' => (string) $format->length);
350
+        $playbackarray[(string)$format->type] = array('type' => (string)$format->type,
351
+            'url' => (string)$format->url, 'length' => (string)$format->length);
352 352
         // Add preview per format when existing.
353 353
         if ($format->preview) {
354 354
             $imagesarray = array();
355 355
             foreach ($format->preview->images->image as $image) {
356
-                $imagearray = array('url' => (string) $image);
356
+                $imagearray = array('url' => (string)$image);
357 357
                 foreach ($image->attributes() as $attkey => $attvalue) {
358
-                    $imagearray[$attkey] = (string) $attvalue;
358
+                    $imagearray[$attkey] = (string)$attvalue;
359 359
                 }
360 360
                 array_push($imagesarray, $imagearray);
361 361
             }
362
-            $playbackarray[(string) $format->type]['preview'] = $imagesarray;
362
+            $playbackarray[(string)$format->type]['preview'] = $imagesarray;
363 363
         }
364 364
     }
365 365
 
366 366
     // Add the metadata to the recordings array.
367 367
     $metadataarray = bigbluebuttonbn_get_recording_array_meta(get_object_vars($recording->metadata));
368
-    $recordingarray = array('recordID' => (string) $recording->recordID,
369
-        'meetingID' => (string) $recording->meetingID, 'meetingName' => (string) $recording->name,
370
-        'published' => (string) $recording->published, 'startTime' => (string) $recording->startTime,
371
-        'endTime' => (string) $recording->endTime, 'playbacks' => $playbackarray);
368
+    $recordingarray = array('recordID' => (string)$recording->recordID,
369
+        'meetingID' => (string)$recording->meetingID, 'meetingName' => (string)$recording->name,
370
+        'published' => (string)$recording->published, 'startTime' => (string)$recording->startTime,
371
+        'endTime' => (string)$recording->endTime, 'playbacks' => $playbackarray);
372 372
     if (isset($recording->protected)) {
373
-        $recordingarray['protected'] = (string) $recording->protected;
373
+        $recordingarray['protected'] = (string)$recording->protected;
374 374
     }
375 375
     // Force protected.
376 376
     $recordingarray['protected'] = 'false';
@@ -383,7 +383,7 @@  discard block
 block discarded – undo
383 383
         if (is_object($value)) {
384 384
             $value = '';
385 385
         }
386
-        $metadataarray['meta_'.$key] = $value;
386
+        $metadataarray['meta_' . $key] = $value;
387 387
     }
388 388
     return $metadataarray;
389 389
 }
@@ -441,7 +441,7 @@  discard block
 block discarded – undo
441 441
     $ids = explode(',', $recordids);
442 442
     foreach ($ids as $id) {
443 443
         $xml = bigbluebuttonbn_wrap_xml_load_file(
444
-            \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('updateRecordings', ['recordID' => $id] + (array) $params)
444
+            \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('updateRecordings', ['recordID' => $id] + (array)$params)
445 445
           );
446 446
         if ($xml && $xml->returncode != 'SUCCESS') {
447 447
             return false;
@@ -561,7 +561,7 @@  discard block
 block discarded – undo
561 561
             return $xml;
562 562
         } catch (Exception $e) {
563 563
             libxml_use_internal_errors($previous);
564
-            $error = 'Caught exception: '.$e->getMessage();
564
+            $error = 'Caught exception: ' . $e->getMessage();
565 565
             debugging($error, DEBUG_DEVELOPER);
566 566
             return null;
567 567
         }
@@ -573,7 +573,7 @@  discard block
 block discarded – undo
573 573
         $response = simplexml_load_file($url, 'SimpleXMLElement', LIBXML_NOCDATA | LIBXML_NOBLANKS);
574 574
         return $response;
575 575
     } catch (Exception $e) {
576
-        $error = 'Caught exception: '.$e->getMessage();
576
+        $error = 'Caught exception: ' . $e->getMessage();
577 577
         debugging($error, DEBUG_DEVELOPER);
578 578
         libxml_use_internal_errors($previous);
579 579
         return null;
@@ -591,8 +591,8 @@  discard block
 block discarded – undo
591 591
 
592 592
         $options = array();
593 593
         $options['CURLOPT_HTTPHEADER'] = array(
594
-                 'Content-Type: '.$contenttype,
595
-                 'Content-Length: '.strlen($data),
594
+                 'Content-Type: ' . $contenttype,
595
+                 'Content-Length: ' . strlen($data),
596 596
                  'Content-Language: en-US',
597 597
                );
598 598
 
@@ -609,9 +609,9 @@  discard block
 block discarded – undo
609 609
     if ($userroles) {
610 610
         $where = '';
611 611
         foreach ($userroles as $value) {
612
-            $where .= (empty($where) ? ' WHERE' : ' AND').' id='.$value->roleid;
612
+            $where .= (empty($where) ? ' WHERE' : ' AND') . ' id=' . $value->roleid;
613 613
         }
614
-        $userroles = $DB->get_records_sql('SELECT * FROM {role}'.$where);
614
+        $userroles = $DB->get_records_sql('SELECT * FROM {role}' . $where);
615 615
     }
616 616
 
617 617
     return $userroles;
@@ -624,7 +624,7 @@  discard block
 block discarded – undo
624 624
 }
625 625
 
626 626
 function bigbluebuttonbn_get_users(context $context = null) {
627
-    $users = (array) get_enrolled_users($context,'',0,'u.*',null,0,0,true);
627
+    $users = (array)get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
628 628
     foreach ($users as $key => $value) {
629 629
         $users[$key] = fullname($value);
630 630
     }
@@ -632,7 +632,7 @@  discard block
 block discarded – undo
632 632
 }
633 633
 
634 634
 function bigbluebuttonbn_get_users_select(context $context = null) {
635
-    $users = (array) get_enrolled_users($context,'',0,'u.*',null,0,0,true);
635
+    $users = (array)get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
636 636
     foreach ($users as $key => $value) {
637 637
         $users[$key] = array('id' => $value->id, 'name' => fullname($value));
638 638
     }
@@ -640,7 +640,7 @@  discard block
 block discarded – undo
640 640
 }
641 641
 
642 642
 function bigbluebuttonbn_get_roles(context $context = null) {
643
-    $roles = (array) role_get_names($context);
643
+    $roles = (array)role_get_names($context);
644 644
     foreach ($roles as $key => $value) {
645 645
         $roles[$key] = $value->localname;
646 646
     }
@@ -648,7 +648,7 @@  discard block
 block discarded – undo
648 648
 }
649 649
 
650 650
 function bigbluebuttonbn_get_roles_select(context $context = null) {
651
-    $roles = (array) role_get_names($context);
651
+    $roles = (array)role_get_names($context);
652 652
     foreach ($roles as $key => $value) {
653 653
         $roles[$key] = array('id' => $value->id, 'name' => $value->localname);
654 654
     }
@@ -656,7 +656,7 @@  discard block
 block discarded – undo
656 656
 }
657 657
 
658 658
 function bigbluebuttonbn_get_role($id) {
659
-    $roles = (array) role_get_names();
659
+    $roles = (array)role_get_names();
660 660
     if (is_numeric($id)) {
661 661
         return (object)$roles[$id];
662 662
     }
@@ -704,12 +704,12 @@  discard block
 block discarded – undo
704 704
 function bigbluebuttonbn_get_participant_rules_encoded($bigbluebuttonbn) {
705 705
     $rules = json_decode($bigbluebuttonbn->participants, true);
706 706
     foreach ($rules as $key => $rule) {
707
-        if ( $rule['selectiontype'] !== 'role' || is_numeric($rule['selectionid']) ) {
707
+        if ($rule['selectiontype'] !== 'role' || is_numeric($rule['selectionid'])) {
708 708
             continue;
709 709
         }
710 710
 
711 711
         $role = bigbluebuttonbn_get_role($rule['selectionid']);
712
-        if ( $role == null ) {
712
+        if ($role == null) {
713 713
             unset($rules[$key]);
714 714
             continue;
715 715
         }
@@ -831,9 +831,9 @@  discard block
 block discarded – undo
831 831
     $isunique = true;
832 832
     if ($voicebridge != 0) {
833 833
         $table = 'bigbluebuttonbn';
834
-        $select = 'voicebridge = '.$voicebridge;
834
+        $select = 'voicebridge = ' . $voicebridge;
835 835
         if ($id) {
836
-            $select .= ' AND id <> '.$id;
836
+            $select .= ' AND id <> ' . $id;
837 837
         }
838 838
         if ($DB->get_records_select($table, $select)) {
839 839
             $isunique = false;
@@ -901,7 +901,7 @@  discard block
 block discarded – undo
901 901
     $mt = microtime();
902 902
     $rand = mt_rand();
903 903
 
904
-    return md5($mt.$rand);
904
+    return md5($mt . $rand);
905 905
 }
906 906
 
907 907
 function bigbluebuttonbn_random_password($length = 8) {
@@ -913,41 +913,41 @@  discard block
 block discarded – undo
913 913
 
914 914
 function bigbluebuttonbn_events() {
915 915
     return array(
916
-        (string) BIGBLUEBUTTON_EVENT_ACTIVITY_VIEWED,
917
-        (string) BIGBLUEBUTTON_EVENT_ACTIVITY_MANAGEMENT_VIEWED,
918
-        (string) BIGBLUEBUTTON_EVENT_LIVE_SESSION,
919
-        (string) BIGBLUEBUTTON_EVENT_MEETING_CREATED,
920
-        (string) BIGBLUEBUTTON_EVENT_MEETING_ENDED,
921
-        (string) BIGBLUEBUTTON_EVENT_MEETING_JOINED,
922
-        (string) BIGBLUEBUTTON_EVENT_MEETING_LEFT,
923
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_DELETED,
924
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_IMPORTED,
925
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_PROTECTED,
926
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_PUBLISHED,
927
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_UNPROTECTED,
928
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_UNPUBLISHED,
929
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_EDITED,
930
-        (string) BIGBLUEBUTTON_EVENT_RECORDING_VIEWED
916
+        (string)BIGBLUEBUTTON_EVENT_ACTIVITY_VIEWED,
917
+        (string)BIGBLUEBUTTON_EVENT_ACTIVITY_MANAGEMENT_VIEWED,
918
+        (string)BIGBLUEBUTTON_EVENT_LIVE_SESSION,
919
+        (string)BIGBLUEBUTTON_EVENT_MEETING_CREATED,
920
+        (string)BIGBLUEBUTTON_EVENT_MEETING_ENDED,
921
+        (string)BIGBLUEBUTTON_EVENT_MEETING_JOINED,
922
+        (string)BIGBLUEBUTTON_EVENT_MEETING_LEFT,
923
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_DELETED,
924
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_IMPORTED,
925
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_PROTECTED,
926
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_PUBLISHED,
927
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_UNPROTECTED,
928
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_UNPUBLISHED,
929
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_EDITED,
930
+        (string)BIGBLUEBUTTON_EVENT_RECORDING_VIEWED
931 931
     );
932 932
 }
933 933
 
934 934
 function bigbluebuttonbn_events_action() {
935 935
     return array(
936
-        'view' => (string) BIGBLUEBUTTON_EVENT_ACTIVITY_VIEWED,
937
-        'view_management' => (string) BIGBLUEBUTTON_EVENT_ACTIVITY_MANAGEMENT_VIEWED,
938
-        'live_action' => (string) BIGBLUEBUTTON_EVENT_LIVE_SESSION,
939
-        'meeting_create' => (string) BIGBLUEBUTTON_EVENT_MEETING_CREATED,
940
-        'meeting_end' => (string) BIGBLUEBUTTON_EVENT_MEETING_ENDED,
941
-        'meeting_join' => (string) BIGBLUEBUTTON_EVENT_MEETING_JOINED,
942
-        'meeting_left' => (string) BIGBLUEBUTTON_EVENT_MEETING_LEFT,
943
-        'recording_delete' => (string) BIGBLUEBUTTON_EVENT_RECORDING_DELETED,
944
-        'recording_import' => (string) BIGBLUEBUTTON_EVENT_RECORDING_IMPORTED,
945
-        'recording_protect' => (string) BIGBLUEBUTTON_EVENT_RECORDING_PROTECTED,
946
-        'recording_publish' => (string) BIGBLUEBUTTON_EVENT_RECORDING_PUBLISHED,
947
-        'recording_unprotect' => (string) BIGBLUEBUTTON_EVENT_RECORDING_UNPROTECTED,
948
-        'recording_unpublish' => (string) BIGBLUEBUTTON_EVENT_RECORDING_UNPUBLISHED,
949
-        'recording_edit' => (string) BIGBLUEBUTTON_EVENT_RECORDING_EDITED,
950
-        'recording_play' => (string) BIGBLUEBUTTON_EVENT_RECORDING_VIEWED
936
+        'view' => (string)BIGBLUEBUTTON_EVENT_ACTIVITY_VIEWED,
937
+        'view_management' => (string)BIGBLUEBUTTON_EVENT_ACTIVITY_MANAGEMENT_VIEWED,
938
+        'live_action' => (string)BIGBLUEBUTTON_EVENT_LIVE_SESSION,
939
+        'meeting_create' => (string)BIGBLUEBUTTON_EVENT_MEETING_CREATED,
940
+        'meeting_end' => (string)BIGBLUEBUTTON_EVENT_MEETING_ENDED,
941
+        'meeting_join' => (string)BIGBLUEBUTTON_EVENT_MEETING_JOINED,
942
+        'meeting_left' => (string)BIGBLUEBUTTON_EVENT_MEETING_LEFT,
943
+        'recording_delete' => (string)BIGBLUEBUTTON_EVENT_RECORDING_DELETED,
944
+        'recording_import' => (string)BIGBLUEBUTTON_EVENT_RECORDING_IMPORTED,
945
+        'recording_protect' => (string)BIGBLUEBUTTON_EVENT_RECORDING_PROTECTED,
946
+        'recording_publish' => (string)BIGBLUEBUTTON_EVENT_RECORDING_PUBLISHED,
947
+        'recording_unprotect' => (string)BIGBLUEBUTTON_EVENT_RECORDING_UNPROTECTED,
948
+        'recording_unpublish' => (string)BIGBLUEBUTTON_EVENT_RECORDING_UNPUBLISHED,
949
+        'recording_edit' => (string)BIGBLUEBUTTON_EVENT_RECORDING_EDITED,
950
+        'recording_play' => (string)BIGBLUEBUTTON_EVENT_RECORDING_VIEWED
951 951
     );
952 952
 }
953 953
 
@@ -971,7 +971,7 @@  discard block
 block discarded – undo
971 971
         $eventproperties['other'] = $options['other'];
972 972
     }
973 973
 
974
-    $event = call_user_func_array('\mod_bigbluebuttonbn\event\bigbluebuttonbn_'.$eventtype.'::create',
974
+    $event = call_user_func_array('\mod_bigbluebuttonbn\event\bigbluebuttonbn_' . $eventtype . '::create',
975 975
       array($eventproperties));
976 976
     $event->trigger();
977 977
 }
@@ -1014,11 +1014,11 @@  discard block
 block discarded – undo
1014 1014
     $now = time();
1015 1015
     if (!$forced && isset($result) && $now < ($result['creation_time'] + $cachettl)) {
1016 1016
         // Use the value in the cache.
1017
-        return (array) json_decode($result['meeting_info']);
1017
+        return (array)json_decode($result['meeting_info']);
1018 1018
     }
1019 1019
 
1020 1020
     // Ping again and refresh the cache.
1021
-    $meetinginfo = (array) bigbluebuttonbn_wrap_xml_load_file(
1021
+    $meetinginfo = (array)bigbluebuttonbn_wrap_xml_load_file(
1022 1022
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid])
1023 1023
       );
1024 1024
     $cache->set($meetingid, array('creation_time' => time(), 'meeting_info' => json_encode($meetinginfo)));
@@ -1076,8 +1076,8 @@  discard block
 block discarded – undo
1076 1076
  * @param string $configxml
1077 1077
  */
1078 1078
 function bigbluebuttonbn_set_config_xml_params($meetingid, $configxml) {
1079
-    $params = 'configXML='.urlencode($configxml).'&meetingID='.urlencode($meetingid);
1080
-    $configxmlparams = $params.'&checksum='.sha1('setConfigXML'.$params.\mod_bigbluebuttonbn\locallib\config::get('shared_secret'));
1079
+    $params = 'configXML=' . urlencode($configxml) . '&meetingID=' . urlencode($meetingid);
1080
+    $configxmlparams = $params . '&checksum=' . sha1('setConfigXML' . $params . \mod_bigbluebuttonbn\locallib\config::get('shared_secret'));
1081 1081
 
1082 1082
     return $configxmlparams;
1083 1083
 }
@@ -1087,7 +1087,7 @@  discard block
 block discarded – undo
1087 1087
  * @param string $configxml
1088 1088
  */
1089 1089
 function bigbluebuttonbn_set_config_xml($meetingid, $configxml) {
1090
-    $urldefaultconfig = \mod_bigbluebuttonbn\locallib\config::get('server_url').'api/setConfigXML?';
1090
+    $urldefaultconfig = \mod_bigbluebuttonbn\locallib\config::get('server_url') . 'api/setConfigXML?';
1091 1091
     $configxmlparams = bigbluebuttonbn_set_config_xml_params($meetingid, $configxml);
1092 1092
     $xml = bigbluebuttonbn_wrap_xml_load_file($urldefaultconfig, BIGBLUEBUTTONBN_METHOD_POST,
1093 1093
         $configxmlparams, 'application/x-www-form-urlencoded');
@@ -1101,7 +1101,7 @@  discard block
 block discarded – undo
1101 1101
  */
1102 1102
 function bigbluebuttonbn_set_config_xml_array($meetingid, $configxml) {
1103 1103
     $configxml = bigbluebuttonbn_setConfigXML($meetingid, $configxml);
1104
-    $configxmlarray = (array) $configxml;
1104
+    $configxmlarray = (array)$configxml;
1105 1105
     if ($configxmlarray['returncode'] != 'SUCCESS') {
1106 1106
         debugging('BigBlueButton was not able to set the custom config.xml file', DEBUG_DEVELOPER);
1107 1107
         return '';
@@ -1138,7 +1138,7 @@  discard block
 block discarded – undo
1138 1138
         $starttime = $starttime - ($starttime % 1000);
1139 1139
 
1140 1140
         // Set formatted date.
1141
-        $dateformat = get_string('strftimerecentfull', 'langconfig').' %Z';
1141
+        $dateformat = get_string('strftimerecentfull', 'langconfig') . ' %Z';
1142 1142
         $row->date_formatted = userdate($starttime / 1000, $dateformat, usertimezone($USER->timezone));
1143 1143
 
1144 1144
         // Set formatted duration.
@@ -1209,7 +1209,7 @@  discard block
 block discarded – undo
1209 1209
     }
1210 1210
 
1211 1211
     $recordingpreview = html_writer::start_tag('div',
1212
-        array('id' => 'preview-'.$recording['recordID'], $visibility => $visibility));
1212
+        array('id' => 'preview-' . $recording['recordID'], $visibility => $visibility));
1213 1213
     foreach ($recording['playbacks'] as $playback) {
1214 1214
         if (isset($playback['preview'])) {
1215 1215
             foreach ($playback['preview'] as $image) {
@@ -1242,19 +1242,19 @@  discard block
 block discarded – undo
1242 1242
         $visibility = 'hidden ';
1243 1243
     }
1244 1244
 
1245
-    $id = 'playbacks-'.$recording['recordID'];
1245
+    $id = 'playbacks-' . $recording['recordID'];
1246 1246
     $recordingtypes = html_writer::start_tag('div', array('id' => $id, 'data-imported' => $dataimported,
1247 1247
           'data-recordingid' => $recording['recordID'], 'data-meetingid' => $recording['meetingID'],
1248 1248
           'title' => $title, $visibility => $visibility));
1249 1249
     foreach ($recording['playbacks'] as $playback) {
1250 1250
         $onclick = 'M.mod_bigbluebuttonbn.recordings.recording_play(this);';
1251
-        $href = $CFG->wwwroot.'/mod/bigbluebuttonbn/bbb_view.php?action=playback&bn='.$bigbluebuttonbnid.
1252
-            '&href='.urlencode($playback['url']).'&rid='.$recording['recordID'];
1253
-        $linkattributes = array('title' => get_string('view_recording_format_'.$playback['type'], 'bigbluebuttonbn'),
1251
+        $href = $CFG->wwwroot . '/mod/bigbluebuttonbn/bbb_view.php?action=playback&bn=' . $bigbluebuttonbnid .
1252
+            '&href=' . urlencode($playback['url']) . '&rid=' . $recording['recordID'];
1253
+        $linkattributes = array('title' => get_string('view_recording_format_' . $playback['type'], 'bigbluebuttonbn'),
1254 1254
             'class' => 'btn btn-sm btn-default', 'onclick' => $onclick,
1255 1255
             'data-action' => 'play', 'data-href' => $href);
1256
-        $recordingtypes .= $OUTPUT->action_link('#', get_string('view_recording_format_'.$playback['type'],
1257
-            'bigbluebuttonbn'), null, $linkattributes).'&#32;';
1256
+        $recordingtypes .= $OUTPUT->action_link('#', get_string('view_recording_format_' . $playback['type'],
1257
+            'bigbluebuttonbn'), null, $linkattributes) . '&#32;';
1258 1258
     }
1259 1259
     $recordingtypes .= html_writer::end_tag('div');
1260 1260
 
@@ -1339,11 +1339,11 @@  discard block
 block discarded – undo
1339 1339
         $target .= '-' . $data['target'];
1340 1340
     }
1341 1341
     $id = 'recording-' . $target . '-' . $recording['recordID'];
1342
-    $onclick = 'M.mod_bigbluebuttonbn.recordings.recording_'.$data['action'].'(this);';
1342
+    $onclick = 'M.mod_bigbluebuttonbn.recordings.recording_' . $data['action'] . '(this);';
1343 1343
     if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recording_icons_enabled')) {
1344 1344
         // With icon for $manageaction.
1345 1345
         $iconattributes = array('id' => $id, 'class' => 'iconsmall');
1346
-        $icon = new pix_icon('i/'.$data['tag'],
1346
+        $icon = new pix_icon('i/' . $data['tag'],
1347 1347
             get_string('view_recording_list_actionbar_' . $data['action'], 'bigbluebuttonbn'),
1348 1348
             'moodle', $iconattributes);
1349 1349
         $linkattributes = array(
@@ -1433,7 +1433,7 @@  discard block
 block discarded – undo
1433 1433
     if (isset($recordings) && !array_key_exists('messageKey', $recordings)) {
1434 1434
         // There are recordings for this meeting.
1435 1435
         foreach ($recordings as $recording) {
1436
-            if ( !bigbluebuttonbn_include_recording_table_row($bbbsession, $recording) ) {
1436
+            if (!bigbluebuttonbn_include_recording_table_row($bbbsession, $recording)) {
1437 1437
                 continue;
1438 1438
             }
1439 1439
             bigbluebuttonbn_get_recording_table_row($bbbsession, $recording, $tools, $table);
@@ -1445,7 +1445,7 @@  discard block
 block discarded – undo
1445 1445
 
1446 1446
 function bigbluebuttonbn_get_recording_table_row($bbbsession, $recording, $tools, &$table) {
1447 1447
     $row = new html_table_row();
1448
-    $row->id = 'recording-td-'.$recording['recordID'];
1448
+    $row->id = 'recording-td-' . $recording['recordID'];
1449 1449
     $row->attributes['data-imported'] = 'false';
1450 1450
     $texthead = '';
1451 1451
     $texttail = '';
@@ -1459,9 +1459,9 @@  discard block
 block discarded – undo
1459 1459
     $rowdata = bigbluebuttonbn_get_recording_data_row($bbbsession, $recording, $tools);
1460 1460
     if ($rowdata != null) {
1461 1461
         $rowdata->date_formatted = str_replace(' ', '&nbsp;', $rowdata->date_formatted);
1462
-        $row->cells = array($texthead.$rowdata->recording.$texttail,
1463
-            $texthead.$rowdata->activity.$texttail, $texthead.$rowdata->description.$texttail,
1464
-            $rowdata->preview, $texthead.$rowdata->date_formatted.$texttail,
1462
+        $row->cells = array($texthead . $rowdata->recording . $texttail,
1463
+            $texthead . $rowdata->activity . $texttail, $texthead . $rowdata->description . $texttail,
1464
+            $rowdata->preview, $texthead . $rowdata->date_formatted . $texttail,
1465 1465
             $rowdata->duration_formatted);
1466 1466
         if ($bbbsession['managerecordings']) {
1467 1467
             $row->cells[] = $rowdata->actionbar;
@@ -1471,7 +1471,7 @@  discard block
 block discarded – undo
1471 1471
 }
1472 1472
 
1473 1473
 function bigbluebuttonbn_include_recording_table_row($bbbsession, $recording) {
1474
-    return !( !isset($recording['imported']) && isset($bbbsession['group']) && $recording['meetingID'] != $bbbsession['meetingid'] );
1474
+    return !(!isset($recording['imported']) && isset($bbbsession['group']) && $recording['meetingID'] != $bbbsession['meetingid']);
1475 1475
 }
1476 1476
 
1477 1477
 function bigbluebuttonbn_send_notification_recording_ready($bigbluebuttonbn) {
@@ -1483,9 +1483,9 @@  discard block
 block discarded – undo
1483 1483
     // Build the message_body.
1484 1484
     $msg->activity_type = '';
1485 1485
     $msg->activity_title = $bigbluebuttonbn->name;
1486
-    $messagetext = '<p>'.get_string('email_body_recording_ready_for', 'bigbluebuttonbn').' '.
1487
-        $msg->activity_type.' &quot;'.$msg->activity_title.'&quot; '.
1488
-        get_string('email_body_recording_ready_is_ready', 'bigbluebuttonbn').'.</p>';
1486
+    $messagetext = '<p>' . get_string('email_body_recording_ready_for', 'bigbluebuttonbn') . ' ' .
1487
+        $msg->activity_type . ' &quot;' . $msg->activity_title . '&quot; ' .
1488
+        get_string('email_body_recording_ready_is_ready', 'bigbluebuttonbn') . '.</p>';
1489 1489
 
1490 1490
     bigbluebuttonbn_send_notification($sender, $bigbluebuttonbn, $messagetext);
1491 1491
 }
@@ -1578,15 +1578,15 @@  discard block
 block discarded – undo
1578 1578
 
1579 1579
     // Gather the bigbluebuttonbnids whose meetingids should be included in the getRecordings request'.
1580 1580
     $select = "id <> '{$bigbluebuttonbnid}' AND course = '{$courseid}'";
1581
-    $selectdeleted = "courseid = '{$courseid}' AND bigbluebuttonbnid <> '{$bigbluebuttonbnid}' AND log = '".
1582
-        BIGBLUEBUTTONBN_LOG_EVENT_DELETE."' AND meta like '%has_recordings%' AND meta like '%true%'";
1581
+    $selectdeleted = "courseid = '{$courseid}' AND bigbluebuttonbnid <> '{$bigbluebuttonbnid}' AND log = '" .
1582
+        BIGBLUEBUTTONBN_LOG_EVENT_DELETE . "' AND meta like '%has_recordings%' AND meta like '%true%'";
1583 1583
     if ($bigbluebuttonbnid === null) {
1584 1584
         $select = "course = '{$courseid}'";
1585
-        $selectdeleted = "courseid = '{$courseid}' AND log = '".BIGBLUEBUTTONBN_LOG_EVENT_DELETE.
1585
+        $selectdeleted = "courseid = '{$courseid}' AND log = '" . BIGBLUEBUTTONBN_LOG_EVENT_DELETE .
1586 1586
             "' AND meta like '%has_recordings%' AND meta like '%true%'";
1587 1587
     } else if ($subset) {
1588 1588
         $select = "id = '{$bigbluebuttonbnid}'";
1589
-        $selectdeleted = "bigbluebuttonbnid = '{$bigbluebuttonbnid}' AND log = '".BIGBLUEBUTTONBN_LOG_EVENT_DELETE.
1589
+        $selectdeleted = "bigbluebuttonbnid = '{$bigbluebuttonbnid}' AND log = '" . BIGBLUEBUTTONBN_LOG_EVENT_DELETE .
1590 1590
             "' AND meta like '%has_recordings%' AND meta like '%true%'";
1591 1591
     }
1592 1592
     $bigbluebuttonbns = $DB->get_records_select_menu('bigbluebuttonbn', $select, null, 'id', 'id, meetingid');
@@ -1608,7 +1608,7 @@  discard block
 block discarded – undo
1608 1608
     if (!empty($bigbluebuttonbns)) {
1609 1609
         // Prepare select for loading records based on existent bigbluebuttonbns.
1610 1610
         $sql = 'SELECT DISTINCT meetingid, bigbluebuttonbnid FROM {bigbluebuttonbn_logs} WHERE ';
1611
-        $sql .= '(bigbluebuttonbnid='.implode(' OR bigbluebuttonbnid=', array_keys($bigbluebuttonbns)).')';
1611
+        $sql .= '(bigbluebuttonbnid=' . implode(' OR bigbluebuttonbnid=', array_keys($bigbluebuttonbns)) . ')';
1612 1612
         // Include only Create events and exclude those with record not true.
1613 1613
         $sql .= ' AND log = ? AND meta LIKE ? AND meta LIKE ?';
1614 1614
         // Execute select for loading records based on existent bigbluebuttonbns.
@@ -1700,8 +1700,8 @@  discard block
 block discarded – undo
1700 1700
 function bigbluebuttonbn_format_activity_time($time) {
1701 1701
     $activitytime = '';
1702 1702
     if ($time) {
1703
-        $activitytime = calendar_day_representation($time).' '.
1704
-          get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn').' '.
1703
+        $activitytime = calendar_day_representation($time) . ' ' .
1704
+          get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn') . ' ' .
1705 1705
           calendar_time_representation($time);
1706 1706
     }
1707 1707
 
@@ -1727,7 +1727,7 @@  discard block
 block discarded – undo
1727 1727
 
1728 1728
 function bigbluebuttonbn_get_moderator_email($context) {
1729 1729
     $moderatoremails = array();
1730
-    $users = (array) get_enrolled_users($context,'',0,'u.*',null,0,0,true);
1730
+    $users = (array)get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
1731 1731
     $counter = 0;
1732 1732
     foreach ($users as $key => $user) {
1733 1733
         if ($counter == 5) {
Please login to merge, or discard this patch.
classes/locallib/notifier.php 1 patch
Spacing   +26 added lines, -26 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
         global $USER;
35 35
 
36 36
         // Prepare message.
37
-        $msg = (object) array();
37
+        $msg = (object)array();
38 38
         // Build the message_body.
39 39
         $msg->action = $action;
40 40
         $msg->activity_type = '';
@@ -54,26 +54,26 @@  discard block
 block discarded – undo
54 54
     }
55 55
 
56 56
     public static function notification_msg_html($msg) {
57
-        $messagetext = '<p>'.$msg->activity_type.' &quot;'.$msg->activity_title.'&quot; '.
58
-            get_string('email_body_notification_meeting_has_been', 'bigbluebuttonbn').' '.$msg->action.'.</p>'."\n";
59
-        $messagetext .= '<p><b>'.$msg->activity_title.'</b> '.
60
-            get_string('email_body_notification_meeting_details', 'bigbluebuttonbn').':'."\n";
61
-        $messagetext .= '<table border="0" style="margin: 5px 0 0 20px"><tbody>'."\n";
62
-        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">'.
63
-            get_string('email_body_notification_meeting_title', 'bigbluebuttonbn').': </td><td>'."\n";
64
-        $messagetext .= $msg->activity_title.'</td></tr>'."\n";
65
-        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">'.
66
-            get_string('email_body_notification_meeting_description', 'bigbluebuttonbn').': </td><td>'."\n";
67
-        $messagetext .= $msg->activity_description.'</td></tr>'."\n";
68
-        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">'.
69
-            get_string('email_body_notification_meeting_start_date', 'bigbluebuttonbn').': </td><td>'."\n";
70
-        $messagetext .= $msg->activity_openingtime.'</td></tr>'."\n";
71
-        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">'.
72
-            get_string('email_body_notification_meeting_end_date', 'bigbluebuttonbn').': </td><td>'."\n";
73
-        $messagetext .= $msg->activity_closingtime.'</td></tr>'."\n";
74
-        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">'.$msg->action.' '.
75
-            get_string('email_body_notification_meeting_by', 'bigbluebuttonbn').': </td><td>'."\n";
76
-        $messagetext .= $msg->activity_owner.'</td></tr></tbody></table></p>'."\n";
57
+        $messagetext = '<p>' . $msg->activity_type . ' &quot;' . $msg->activity_title . '&quot; ' .
58
+            get_string('email_body_notification_meeting_has_been', 'bigbluebuttonbn') . ' ' . $msg->action . '.</p>' . "\n";
59
+        $messagetext .= '<p><b>' . $msg->activity_title . '</b> ' .
60
+            get_string('email_body_notification_meeting_details', 'bigbluebuttonbn') . ':' . "\n";
61
+        $messagetext .= '<table border="0" style="margin: 5px 0 0 20px"><tbody>' . "\n";
62
+        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">' .
63
+            get_string('email_body_notification_meeting_title', 'bigbluebuttonbn') . ': </td><td>' . "\n";
64
+        $messagetext .= $msg->activity_title . '</td></tr>' . "\n";
65
+        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">' .
66
+            get_string('email_body_notification_meeting_description', 'bigbluebuttonbn') . ': </td><td>' . "\n";
67
+        $messagetext .= $msg->activity_description . '</td></tr>' . "\n";
68
+        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">' .
69
+            get_string('email_body_notification_meeting_start_date', 'bigbluebuttonbn') . ': </td><td>' . "\n";
70
+        $messagetext .= $msg->activity_openingtime . '</td></tr>' . "\n";
71
+        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">' .
72
+            get_string('email_body_notification_meeting_end_date', 'bigbluebuttonbn') . ': </td><td>' . "\n";
73
+        $messagetext .= $msg->activity_closingtime . '</td></tr>' . "\n";
74
+        $messagetext .= '<tr><td style="font-weight:bold;color:#555;">' . $msg->action . ' ' .
75
+            get_string('email_body_notification_meeting_by', 'bigbluebuttonbn') . ': </td><td>' . "\n";
76
+        $messagetext .= $msg->activity_owner . '</td></tr></tbody></table></p>' . "\n";
77 77
         return $messagetext;
78 78
     }
79 79
 
@@ -83,15 +83,15 @@  discard block
 block discarded – undo
83 83
         $course = $DB->get_record('course', array('id' => $bigbluebuttonbn->course), '*', MUST_EXIST);
84 84
 
85 85
         // Complete message.
86
-        $msg = (object) array();
86
+        $msg = (object)array();
87 87
         $msg->user_name = fullname($sender);
88 88
         $msg->user_email = $sender->email;
89 89
         $msg->course_name = "$course->fullname";
90
-        $message .= '<p><hr/><br/>'.get_string('email_footer_sent_by', 'bigbluebuttonbn').' '.
91
-            $msg->user_name.'('.$msg->user_email.') ';
92
-        $message .= get_string('email_footer_sent_from', 'bigbluebuttonbn').' '.$msg->course_name.'.</p>';
90
+        $message .= '<p><hr/><br/>' . get_string('email_footer_sent_by', 'bigbluebuttonbn') . ' ' .
91
+            $msg->user_name . '(' . $msg->user_email . ') ';
92
+        $message .= get_string('email_footer_sent_from', 'bigbluebuttonbn') . ' ' . $msg->course_name . '.</p>';
93 93
 
94
-        $users = (array) get_enrolled_users($context,'',0,'u.*',null,0,0,true);
94
+        $users = (array)get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
95 95
         foreach ($users as $user) {
96 96
             if ($user->id != $sender->id) {
97 97
                 message_post_message($sender, $user, $message, FORMAT_HTML);
Please login to merge, or discard this patch.
classes/locallib/bigbluebutton.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -37,17 +37,17 @@
 block discarded – undo
37 37
      * @return string
38 38
      */
39 39
     public static function action_url($action = '', $data = array(), $metadata = array()) {
40
-        $baseurl = \mod_bigbluebuttonbn\locallib\config::get('server_url').'api/'.$action.'?';
40
+        $baseurl = \mod_bigbluebuttonbn\locallib\config::get('server_url') . 'api/' . $action . '?';
41 41
         $params = '';
42 42
 
43 43
         foreach ($data as $key => $value) {
44
-            $params .= '&'.$key.'='.urlencode($value);
44
+            $params .= '&' . $key . '=' . urlencode($value);
45 45
         }
46 46
 
47 47
         foreach ($metadata as $key => $value) {
48
-            $params .= '&'.'meta_'.$key.'='.urlencode($value);
48
+            $params .= '&' . 'meta_' . $key . '=' . urlencode($value);
49 49
         }
50 50
 
51
-        return $baseurl.$params.'&checksum='.sha1($action.$params.\mod_bigbluebuttonbn\locallib\config::get('shared_secret'));
51
+        return $baseurl . $params . '&checksum=' . sha1($action . $params . \mod_bigbluebuttonbn\locallib\config::get('shared_secret'));
52 52
     }
53 53
 }
Please login to merge, or discard this patch.
classes/locallib/config.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -47,8 +47,8 @@  discard block
 block discarded – undo
47 47
      */
48 48
     public static function defaultvalues() {
49 49
         return array(
50
-            'server_url' => (string) BIGBLUEBUTTONBN_DEFAULT_SERVER_URL,
51
-            'server_url' => (string) BIGBLUEBUTTONBN_DEFAULT_SHARED_SECRET,
50
+            'server_url' => (string)BIGBLUEBUTTONBN_DEFAULT_SERVER_URL,
51
+            'server_url' => (string)BIGBLUEBUTTONBN_DEFAULT_SHARED_SECRET,
52 52
             'importrecordings_enabled' => 'false',
53 53
             'voicebridge_editable' => 'false',
54 54
             'recording_default' => 'true',
@@ -98,11 +98,11 @@  discard block
 block discarded – undo
98 98
         global $CFG;
99 99
 
100 100
         if (isset($CFG->bigbluebuttonbn[$setting])) {
101
-            return (string) $CFG->bigbluebuttonbn[$setting];
101
+            return (string)$CFG->bigbluebuttonbn[$setting];
102 102
         }
103 103
 
104
-        if (isset($CFG->{'bigbluebuttonbn_'.$setting})) {
105
-            return (string)$CFG->{'bigbluebuttonbn_'.$setting};
104
+        if (isset($CFG->{'bigbluebuttonbn_' . $setting})) {
105
+            return (string)$CFG->{'bigbluebuttonbn_' . $setting};
106 106
         }
107 107
 
108 108
         return  self::defaultvalue($setting);
Please login to merge, or discard this patch.
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -122,23 +122,23 @@
 block discarded – undo
122 122
      */
123 123
     public static function get_options() {
124 124
         return [
125
-               'version_major' => self::get_moodle_version_major(),
126
-               'voicebridge_editable' => self::get('voicebridge_editable'),
127
-               'recording_default' => self::get('recording_default'),
128
-               'recording_editable' => self::get('recording_editable'),
129
-               'waitformoderator_default' => self::get('waitformoderator_default'),
130
-               'waitformoderator_editable' => self::get('waitformoderator_editable'),
131
-               'userlimit_default' => self::get('userlimit_default'),
132
-               'userlimit_editable' => self::get('userlimit_editable'),
133
-               'preuploadpresentation_enabled' => self::get('preuploadpresentation_enabled'),
134
-               'sendnotifications_enabled' => self::get('sendnotifications_enabled'),
135
-               'recordings_html_default' => self::get('recordings_html_default'),
136
-               'recordings_html_editable' => self::get('recordings_html_editable'),
137
-               'recordings_deleted_activities_default' => self::get('recordings_deleted_activities_default'),
138
-               'recordings_deleted_activities_editable' => self::get('recordings_deleted_activities_editable'),
139
-               'recording_icons_enabled' => self::get('recording_icons_enabled'),
140
-               'instance_type_enabled' => self::recordings_enabled(),
141
-               'instance_type_default' => BIGBLUEBUTTONBN_TYPE_ALL,
142
-          ];
125
+                'version_major' => self::get_moodle_version_major(),
126
+                'voicebridge_editable' => self::get('voicebridge_editable'),
127
+                'recording_default' => self::get('recording_default'),
128
+                'recording_editable' => self::get('recording_editable'),
129
+                'waitformoderator_default' => self::get('waitformoderator_default'),
130
+                'waitformoderator_editable' => self::get('waitformoderator_editable'),
131
+                'userlimit_default' => self::get('userlimit_default'),
132
+                'userlimit_editable' => self::get('userlimit_editable'),
133
+                'preuploadpresentation_enabled' => self::get('preuploadpresentation_enabled'),
134
+                'sendnotifications_enabled' => self::get('sendnotifications_enabled'),
135
+                'recordings_html_default' => self::get('recordings_html_default'),
136
+                'recordings_html_editable' => self::get('recordings_html_editable'),
137
+                'recordings_deleted_activities_default' => self::get('recordings_deleted_activities_default'),
138
+                'recordings_deleted_activities_editable' => self::get('recordings_deleted_activities_editable'),
139
+                'recording_icons_enabled' => self::get('recording_icons_enabled'),
140
+                'instance_type_enabled' => self::recordings_enabled(),
141
+                'instance_type_default' => BIGBLUEBUTTONBN_TYPE_ALL,
142
+            ];
143 143
     }
144 144
 }
Please login to merge, or discard this patch.
classes/event/bigbluebuttonbn_live_session_event.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,8 +34,8 @@
 block discarded – undo
34 34
      */
35 35
     protected function init() {
36 36
         parent::init();
37
-        $this->description = "The user with id '$this->userid' triggered action $this->other in a ".
38
-        "bigbluebutton meeting for the bigbluebuttonbn activity with id ".
37
+        $this->description = "The user with id '$this->userid' triggered action $this->other in a " .
38
+        "bigbluebutton meeting for the bigbluebuttonbn activity with id " .
39 39
         "'$this->objectid' for the course id '$this->contextinstanceid'.";
40 40
     }
41 41
 
Please login to merge, or discard this patch.
classes/event/bigbluebuttonbn_recording_unprotected.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
      */
35 35
     protected function init() {
36 36
         parent::init();
37
-        $this->description = "The user with id '$this->userid' has unprotected a recording with id ".
37
+        $this->description = "The user with id '$this->userid' has unprotected a recording with id " .
38 38
             "'$this->other' in the course id '$this->contextinstanceid'.";
39 39
     }
40 40
 
Please login to merge, or discard this patch.