Completed
Pull Request — master (#216)
by
unknown
01:56
created
locallib.php 1 patch
Spacing   +56 added lines, -56 removed lines patch added patch discarded remove patch
@@ -190,7 +190,7 @@  discard block
 block discarded – undo
190 190
     }
191 191
     if ($xml) {
192 192
         // Either failure or success without meeting info.
193
-        return (array) $xml;
193
+        return (array)$xml;
194 194
     }
195 195
     // If the server is unreachable, then prompts the user of the necessary action.
196 196
     return array('returncode' => 'FAILED', 'message' => 'unreachable', 'messageKey' => 'Server is unreachable');
@@ -279,7 +279,7 @@  discard block
 block discarded – undo
279 279
                 foreach ($recordingxml->breakoutRooms->breakoutRoom as $breakoutroom) {
280 280
                     $url = \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url(
281 281
                         'getRecordings',
282
-                        ['recordID' => implode(',', (array) $breakoutroom)]
282
+                        ['recordID' => implode(',', (array)$breakoutroom)]
283 283
                     );
284 284
                     $xml = bigbluebuttonbn_wrap_xml_load_file($url);
285 285
                     if ($xml && $xml->returncode == 'SUCCESS' && isset($xml->recordings)) {
@@ -335,7 +335,7 @@  discard block
 block discarded – undo
335 335
         // Override imported flag with actual ID.
336 336
         $recording['imported'] = $recordimported->id;
337 337
         if (isset($recordimported->protected)) {
338
-            $recording['protected'] = (string) $recordimported->protected;
338
+            $recording['protected'] = (string)$recordimported->protected;
339 339
         }
340 340
         $recordsimportedarray[$recording['recordID']] = $recording;
341 341
     }
@@ -365,21 +365,21 @@  discard block
 block discarded – undo
365 365
     // Add formats.
366 366
     $playbackarray = array();
367 367
     foreach ($recording->playback->format as $format) {
368
-        $playbackarray[(string) $format->type] = array('type' => (string) $format->type,
369
-            'url' => trim((string) $format->url), 'length' => (string) $format->length);
368
+        $playbackarray[(string)$format->type] = array('type' => (string)$format->type,
369
+            'url' => trim((string)$format->url), 'length' => (string)$format->length);
370 370
         // Add preview per format when existing.
371 371
         if ($format->preview) {
372
-            $playbackarray[(string) $format->type]['preview'] = bigbluebuttonbn_get_recording_preview_images($format->preview);
372
+            $playbackarray[(string)$format->type]['preview'] = bigbluebuttonbn_get_recording_preview_images($format->preview);
373 373
         }
374 374
     }
375 375
     // Add the metadata to the recordings array.
376 376
     $metadataarray = bigbluebuttonbn_get_recording_array_meta(get_object_vars($recording->metadata));
377
-    $recordingarray = array('recordID' => (string) $recording->recordID,
378
-        'meetingID' => (string) $recording->meetingID, 'meetingName' => (string) $recording->name,
379
-        'published' => (string) $recording->published, 'startTime' => (string) $recording->startTime,
380
-        'endTime' => (string) $recording->endTime, 'playbacks' => $playbackarray);
377
+    $recordingarray = array('recordID' => (string)$recording->recordID,
378
+        'meetingID' => (string)$recording->meetingID, 'meetingName' => (string)$recording->name,
379
+        'published' => (string)$recording->published, 'startTime' => (string)$recording->startTime,
380
+        'endTime' => (string)$recording->endTime, 'playbacks' => $playbackarray);
381 381
     if (isset($recording->protected)) {
382
-        $recordingarray['protected'] = (string) $recording->protected;
382
+        $recordingarray['protected'] = (string)$recording->protected;
383 383
     }
384 384
     return $recordingarray + $metadataarray;
385 385
 }
@@ -394,9 +394,9 @@  discard block
 block discarded – undo
394 394
 function bigbluebuttonbn_get_recording_preview_images($preview) {
395 395
     $imagesarray = array();
396 396
     foreach ($preview->images->image as $image) {
397
-        $imagearray = array('url' => trim((string) $image));
397
+        $imagearray = array('url' => trim((string)$image));
398 398
         foreach ($image->attributes() as $attkey => $attvalue) {
399
-            $imagearray[$attkey] = (string) $attvalue;
399
+            $imagearray[$attkey] = (string)$attvalue;
400 400
         }
401 401
         array_push($imagesarray, $imagearray);
402 402
     }
@@ -491,7 +491,7 @@  discard block
 block discarded – undo
491 491
     $ids = explode(',', $recordids);
492 492
     foreach ($ids as $id) {
493 493
         $xml = bigbluebuttonbn_wrap_xml_load_file(
494
-            \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('updateRecordings', ['recordID' => $id] + (array) $params)
494
+            \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('updateRecordings', ['recordID' => $id] + (array)$params)
495 495
         );
496 496
         if ($xml && $xml->returncode != 'SUCCESS') {
497 497
             return false;
@@ -662,7 +662,7 @@  discard block
 block discarded – undo
662 662
  * @return array $users
663 663
  */
664 664
 function bigbluebuttonbn_get_users(context $context = null) {
665
-    $users = (array) get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
665
+    $users = (array)get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
666 666
     foreach ($users as $key => $value) {
667 667
         $users[$key] = fullname($value);
668 668
     }
@@ -681,7 +681,7 @@  discard block
 block discarded – undo
681 681
 function bigbluebuttonbn_get_users_select(context_course $context, $bbactivity = null) {
682 682
     // CONTRIB-7972, check the group of current user and course group mode.
683 683
     $groups = null;
684
-    $users = (array) get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
684
+    $users = (array)get_enrolled_users($context, '', 0, 'u.*', null, 0, 0, true);
685 685
     $course = get_course($context->instanceid);
686 686
     $groupmode = groups_get_course_groupmode($course);
687 687
     if ($bbactivity) {
@@ -694,7 +694,7 @@  discard block
 block discarded – undo
694 694
         $groups = groups_get_all_groups($course->id, $USER->id);
695 695
         $users = [];
696 696
         foreach ($groups as $g) {
697
-            $users += (array) get_enrolled_users($context, '', $g->id, 'u.*', null, 0, 0, true);
697
+            $users += (array)get_enrolled_users($context, '', $g->id, 'u.*', null, 0, 0, true);
698 698
         }
699 699
     }
700 700
     return array_map(
@@ -712,7 +712,7 @@  discard block
 block discarded – undo
712 712
  * @return array $roles
713 713
  */
714 714
 function bigbluebuttonbn_get_roles(context $context = null) {
715
-    $roles = (array) role_get_names($context);
715
+    $roles = (array)role_get_names($context);
716 716
     foreach ($roles as $key => $value) {
717 717
         $roles[$key] = $value->localname;
718 718
     }
@@ -727,7 +727,7 @@  discard block
 block discarded – undo
727 727
  * @return array $users
728 728
  */
729 729
 function bigbluebuttonbn_get_roles_select(context $context = null) {
730
-    $roles = (array) role_get_names($context);
730
+    $roles = (array)role_get_names($context);
731 731
     foreach ($roles as $key => $value) {
732 732
         $roles[$key] = array('id' => $value->id, 'name' => $value->localname);
733 733
     }
@@ -742,9 +742,9 @@  discard block
 block discarded – undo
742 742
  * @return object $role
743 743
  */
744 744
 function bigbluebuttonbn_get_role($id) {
745
-    $roles = (array) role_get_names();
745
+    $roles = (array)role_get_names();
746 746
     if (is_numeric($id) && isset($roles[$id])) {
747
-        return (object) $roles[$id];
747
+        return (object)$roles[$id];
748 748
     }
749 749
     foreach ($roles as $role) {
750 750
         if ($role->shortname == $id) {
@@ -824,7 +824,7 @@  discard block
 block discarded – undo
824 824
             if (!empty($ownerid) && is_enrolled($context, $ownerid)) {
825 825
                 $participantlist[] = array(
826 826
                     'selectiontype' => 'user',
827
-                    'selectionid' => (string) $ownerid,
827
+                    'selectionid' => (string)$ownerid,
828 828
                     'role' => BIGBLUEBUTTONBN_ROLE_MODERATOR);
829 829
             }
830 830
             continue;
@@ -1006,7 +1006,7 @@  discard block
 block discarded – undo
1006 1006
     $now = time();
1007 1007
     if ($closingtime > 0 && $now < $closingtime) {
1008 1008
         $duration = ceil(($closingtime - $now) / 60);
1009
-        $compensationtime = intval((int) \mod_bigbluebuttonbn\locallib\config::get('scheduled_duration_compensation'));
1009
+        $compensationtime = intval((int)\mod_bigbluebuttonbn\locallib\config::get('scheduled_duration_compensation'));
1010 1010
         $duration = intval($duration) + $compensationtime;
1011 1011
     }
1012 1012
     return $duration;
@@ -1208,16 +1208,16 @@  discard block
 block discarded – undo
1208 1208
  * @return array
1209 1209
  */
1210 1210
 function bigbluebuttonbn_get_meeting_info($meetingid, $updatecache = false) {
1211
-    $cachettl = (int) \mod_bigbluebuttonbn\locallib\config::get('waitformoderator_cache_ttl');
1211
+    $cachettl = (int)\mod_bigbluebuttonbn\locallib\config::get('waitformoderator_cache_ttl');
1212 1212
     $cache = cache::make_from_params(cache_store::MODE_APPLICATION, 'mod_bigbluebuttonbn', 'meetings_cache');
1213 1213
     $result = $cache->get($meetingid);
1214 1214
     $now = time();
1215 1215
     if (!$updatecache && isset($result) && $now < ($result['creation_time'] + $cachettl)) {
1216 1216
         // Use the value in the cache.
1217
-        return (array) json_decode($result['meeting_info']);
1217
+        return (array)json_decode($result['meeting_info']);
1218 1218
     }
1219 1219
     // Ping again and refresh the cache.
1220
-    $meetinginfo = (array) bigbluebuttonbn_wrap_xml_load_file(
1220
+    $meetinginfo = (array)bigbluebuttonbn_wrap_xml_load_file(
1221 1221
         \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid])
1222 1222
     );
1223 1223
     $cache->set($meetingid, array('creation_time' => time(), 'meeting_info' => json_encode($meetinginfo)));
@@ -1364,7 +1364,7 @@  discard block
 block discarded – undo
1364 1364
  */
1365 1365
 function bigbluebuttonbn_set_config_xml_array($meetingid, $configxml) {
1366 1366
     $configxml = bigbluebuttonbn_setConfigXML($meetingid, $configxml);
1367
-    $configxmlarray = (array) $configxml;
1367
+    $configxmlarray = (array)$configxml;
1368 1368
     if ($configxmlarray['returncode'] != 'SUCCESS') {
1369 1369
         debugging('BigBlueButton was not able to set the custom config.xml file', DEBUG_DEVELOPER);
1370 1370
         return '';
@@ -1417,7 +1417,7 @@  discard block
 block discarded – undo
1417 1417
  * @return boolean
1418 1418
  */
1419 1419
 function bigbluebuttonbn_get_recording_data_row_editable($bbbsession) {
1420
-    return ($bbbsession['managerecordings'] && ((double) $bbbsession['serverversion'] >= 1.0 || $bbbsession['bnserver']));
1420
+    return ($bbbsession['managerecordings'] && ((double)$bbbsession['serverversion'] >= 1.0 || $bbbsession['bnserver']));
1421 1421
 }
1422 1422
 
1423 1423
 /**
@@ -1428,7 +1428,7 @@  discard block
 block discarded – undo
1428 1428
  * @return boolean
1429 1429
  */
1430 1430
 function bigbluebuttonbn_get_recording_data_preview_enabled($bbbsession) {
1431
-    return ((double) $bbbsession['serverversion'] >= 1.0 && $bbbsession['bigbluebuttonbn']->recordings_preview == '1');
1431
+    return ((double)$bbbsession['serverversion'] >= 1.0 && $bbbsession['bigbluebuttonbn']->recordings_preview == '1');
1432 1432
 }
1433 1433
 
1434 1434
 /**
@@ -1852,7 +1852,7 @@  discard block
 block discarded – undo
1852 1852
     }
1853 1853
     $id = 'recording-' . $target . '-' . $recording['recordID'];
1854 1854
     $onclick = 'M.mod_bigbluebuttonbn.recordings.recording' . ucfirst($data['action']) . '(this); return false;';
1855
-    if ((boolean) \mod_bigbluebuttonbn\locallib\config::get('recording_icons_enabled')) {
1855
+    if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recording_icons_enabled')) {
1856 1856
         // With icon for $manageaction.
1857 1857
         $iconattributes = array('id' => $id, 'class' => 'iconsmall');
1858 1858
         $linkattributes = array(
@@ -2131,7 +2131,7 @@  discard block
 block discarded – undo
2131 2131
         // Enqueue it.
2132 2132
         \core\task\manager::queue_adhoc_task($task);
2133 2133
     } catch (Exception $e) {
2134
-        mtrace("Error while enqueuing completion_update_state task. " . (string) $e);
2134
+        mtrace("Error while enqueuing completion_update_state task. " . (string)$e);
2135 2135
     }
2136 2136
 }
2137 2137
 
@@ -2145,7 +2145,7 @@  discard block
 block discarded – undo
2145 2145
  */
2146 2146
 function bigbluebuttonbn_completion_update_state($bigbluebuttonbn, $userid) {
2147 2147
     global $CFG;
2148
-    require_once($CFG->libdir.'/completionlib.php');
2148
+    require_once($CFG->libdir . '/completionlib.php');
2149 2149
     list($course, $cm) = get_course_and_cm_from_instance($bigbluebuttonbn, 'bigbluebuttonbn');
2150 2150
     $completion = new completion_info($course);
2151 2151
     if (!$completion->is_enabled($cm)) {
@@ -2574,7 +2574,7 @@  discard block
 block discarded – undo
2574 2574
  */
2575 2575
 function bigbluebuttonbn_format_activity_time($time) {
2576 2576
     global $CFG;
2577
-    require_once($CFG->dirroot.'/calendar/lib.php');
2577
+    require_once($CFG->dirroot . '/calendar/lib.php');
2578 2578
     $activitytime = '';
2579 2579
     if ($time) {
2580 2580
         $activitytime = calendar_day_representation($time) . ' ' .
@@ -2672,7 +2672,7 @@  discard block
 block discarded – undo
2672 2672
  */
2673 2673
 function bigbluebuttonbn_settings_general(&$renderer) {
2674 2674
     // Configuration for BigBlueButton.
2675
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_general_shown()) {
2675
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_general_shown()) {
2676 2676
         $renderer->render_group_header('general');
2677 2677
         $renderer->render_group_element(
2678 2678
             'server_url',
@@ -2694,7 +2694,7 @@  discard block
 block discarded – undo
2694 2694
  */
2695 2695
 function bigbluebuttonbn_settings_record(&$renderer) {
2696 2696
     // Configuration for 'recording' feature.
2697
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_record_meeting_shown()) {
2697
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_record_meeting_shown()) {
2698 2698
         $renderer->render_group_header('recording');
2699 2699
         $renderer->render_group_element(
2700 2700
             'recording_default',
@@ -2738,7 +2738,7 @@  discard block
 block discarded – undo
2738 2738
  */
2739 2739
 function bigbluebuttonbn_settings_importrecordings(&$renderer) {
2740 2740
     // Configuration for 'import recordings' feature.
2741
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_import_recordings_shown()) {
2741
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_import_recordings_shown()) {
2742 2742
         $renderer->render_group_header('importrecordings');
2743 2743
         $renderer->render_group_element(
2744 2744
             'importrecordings_enabled',
@@ -2760,7 +2760,7 @@  discard block
 block discarded – undo
2760 2760
  */
2761 2761
 function bigbluebuttonbn_settings_showrecordings(&$renderer) {
2762 2762
     // Configuration for 'show recordings' feature.
2763
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_show_recordings_shown()) {
2763
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_show_recordings_shown()) {
2764 2764
         $renderer->render_group_header('recordings');
2765 2765
         $renderer->render_group_element(
2766 2766
             'recordings_html_default',
@@ -2810,7 +2810,7 @@  discard block
 block discarded – undo
2810 2810
  */
2811 2811
 function bigbluebuttonbn_settings_waitmoderator(&$renderer) {
2812 2812
     // Configuration for wait for moderator feature.
2813
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_wait_moderator_shown()) {
2813
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_wait_moderator_shown()) {
2814 2814
         $renderer->render_group_header('waitformoderator');
2815 2815
         $renderer->render_group_element(
2816 2816
             'waitformoderator_default',
@@ -2840,7 +2840,7 @@  discard block
 block discarded – undo
2840 2840
  */
2841 2841
 function bigbluebuttonbn_settings_voicebridge(&$renderer) {
2842 2842
     // Configuration for "static voice bridge" feature.
2843
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_static_voice_bridge_shown()) {
2843
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_static_voice_bridge_shown()) {
2844 2844
         $renderer->render_group_header('voicebridge');
2845 2845
         $renderer->render_group_element(
2846 2846
             'voicebridge_editable',
@@ -2858,7 +2858,7 @@  discard block
 block discarded – undo
2858 2858
  */
2859 2859
 function bigbluebuttonbn_settings_preupload(&$renderer) {
2860 2860
     // Configuration for "preupload presentation" feature.
2861
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_preupload_presentation_shown()) {
2861
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_preupload_presentation_shown()) {
2862 2862
         // This feature only works if curl is installed.
2863 2863
         $preuploaddescripion = get_string('config_preuploadpresentation_description', 'bigbluebuttonbn');
2864 2864
         if (!extension_loaded('curl')) {
@@ -2886,7 +2886,7 @@  discard block
 block discarded – undo
2886 2886
  */
2887 2887
 function bigbluebuttonbn_settings_preupload_manage_default_file(&$renderer) {
2888 2888
     // Configuration for "preupload presentation" feature.
2889
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_preupload_presentation_shown()) {
2889
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_preupload_presentation_shown()) {
2890 2890
         if (extension_loaded('curl')) {
2891 2891
             // This feature only works if curl is installed.
2892 2892
             $renderer->render_filemanager_default_file_presentation("presentation_default");
@@ -2903,7 +2903,7 @@  discard block
 block discarded – undo
2903 2903
  */
2904 2904
 function bigbluebuttonbn_settings_userlimit(&$renderer) {
2905 2905
     // Configuration for "user limit" feature.
2906
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_user_limit_shown()) {
2906
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_user_limit_shown()) {
2907 2907
         $renderer->render_group_header('userlimit');
2908 2908
         $renderer->render_group_element(
2909 2909
             'userlimit_default',
@@ -2925,7 +2925,7 @@  discard block
 block discarded – undo
2925 2925
  */
2926 2926
 function bigbluebuttonbn_settings_duration(&$renderer) {
2927 2927
     // Configuration for "scheduled duration" feature.
2928
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_scheduled_duration_shown()) {
2928
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_scheduled_duration_shown()) {
2929 2929
         $renderer->render_group_header('scheduled');
2930 2930
         $renderer->render_group_element(
2931 2931
             'scheduled_duration_enabled',
@@ -2951,7 +2951,7 @@  discard block
 block discarded – undo
2951 2951
  */
2952 2952
 function bigbluebuttonbn_settings_participants(&$renderer) {
2953 2953
     // Configuration for defining the default role/user that will be moderator on new activities.
2954
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_moderator_default_shown()) {
2954
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_moderator_default_shown()) {
2955 2955
         $renderer->render_group_header('participant');
2956 2956
         // UI for 'participants' feature.
2957 2957
         $roles = bigbluebuttonbn_get_roles();
@@ -2976,7 +2976,7 @@  discard block
 block discarded – undo
2976 2976
  */
2977 2977
 function bigbluebuttonbn_settings_notifications(&$renderer) {
2978 2978
     // Configuration for "send notifications" feature.
2979
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_send_notifications_shown()) {
2979
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_send_notifications_shown()) {
2980 2980
         $renderer->render_group_header('sendnotifications');
2981 2981
         $renderer->render_group_element(
2982 2982
             'sendnotifications_enabled',
@@ -2994,14 +2994,14 @@  discard block
 block discarded – undo
2994 2994
  */
2995 2995
 function bigbluebuttonbn_settings_clienttype(&$renderer) {
2996 2996
     // Configuration for "clienttype" feature.
2997
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_clienttype_shown()) {
2997
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_clienttype_shown()) {
2998 2998
         $renderer->render_group_header('clienttype');
2999 2999
         $renderer->render_group_element(
3000 3000
             'clienttype_editable',
3001 3001
             $renderer->render_group_element_checkbox('clienttype_editable', 0)
3002 3002
         );
3003 3003
         // Web Client default.
3004
-        $default = intval((int) \mod_bigbluebuttonbn\locallib\config::get('clienttype_default'));
3004
+        $default = intval((int)\mod_bigbluebuttonbn\locallib\config::get('clienttype_default'));
3005 3005
         $choices = array(BIGBLUEBUTTON_CLIENTTYPE_FLASH => get_string('mod_form_block_clienttype_flash', 'bigbluebuttonbn'),
3006 3006
             BIGBLUEBUTTON_CLIENTTYPE_HTML5 => get_string('mod_form_block_clienttype_html5', 'bigbluebuttonbn'));
3007 3007
         $renderer->render_group_element(
@@ -3024,7 +3024,7 @@  discard block
 block discarded – undo
3024 3024
  */
3025 3025
 function bigbluebuttonbn_settings_muteonstart(&$renderer) {
3026 3026
     // Configuration for BigBlueButton.
3027
-    if ((boolean) \mod_bigbluebuttonbn\settings\validator::section_muteonstart_shown()) {
3027
+    if ((boolean)\mod_bigbluebuttonbn\settings\validator::section_muteonstart_shown()) {
3028 3028
         $renderer->render_group_header('muteonstart');
3029 3029
         $renderer->render_group_element(
3030 3030
             'muteonstart_default',
@@ -3046,7 +3046,7 @@  discard block
 block discarded – undo
3046 3046
  */
3047 3047
 function bigbluebuttonbn_settings_extended(&$renderer) {
3048 3048
     // Configuration for 'notify users when recording ready' feature.
3049
-    if (!(boolean) \mod_bigbluebuttonbn\settings\validator::section_settings_extended_shown()) {
3049
+    if (!(boolean)\mod_bigbluebuttonbn\settings\validator::section_settings_extended_shown()) {
3050 3050
         return;
3051 3051
     }
3052 3052
     $renderer->render_group_header('extended_capabilities');
@@ -3074,7 +3074,7 @@  discard block
 block discarded – undo
3074 3074
     global $DB;
3075 3075
     do {
3076 3076
         $encodedseed = sha1(bigbluebuttonbn_random_password(12));
3077
-        $meetingid = (string) $DB->get_field('bigbluebuttonbn', 'meetingid', array('meetingid' => $encodedseed));
3077
+        $meetingid = (string)$DB->get_field('bigbluebuttonbn', 'meetingid', array('meetingid' => $encodedseed));
3078 3078
     } while ($meetingid == $encodedseed);
3079 3079
     return $encodedseed;
3080 3080
 }
@@ -3287,7 +3287,7 @@  discard block
 block discarded – undo
3287 3287
 function bigbluebuttonbn_instance_ownerid($bigbluebuttonbn) {
3288 3288
     global $DB;
3289 3289
     $filters = array('bigbluebuttonbnid' => $bigbluebuttonbn->id, 'log' => 'Add');
3290
-    $ownerid = (integer) $DB->get_field('bigbluebuttonbn_logs', 'userid', $filters);
3290
+    $ownerid = (integer)$DB->get_field('bigbluebuttonbn_logs', 'userid', $filters);
3291 3291
     return $ownerid;
3292 3292
 }
3293 3293
 
@@ -3330,8 +3330,8 @@  discard block
 block discarded – undo
3330 3330
     $bbbsession['meetingname'] = $bbbsession['bigbluebuttonbn']->name;
3331 3331
     $bbbsession['meetingdescription'] = $bbbsession['bigbluebuttonbn']->intro;
3332 3332
     // Extra data for setting up the Meeting.
3333
-    $bbbsession['userlimit'] = intval((int) \mod_bigbluebuttonbn\locallib\config::get('userlimit_default'));
3334
-    if ((boolean) \mod_bigbluebuttonbn\locallib\config::get('userlimit_editable')) {
3333
+    $bbbsession['userlimit'] = intval((int)\mod_bigbluebuttonbn\locallib\config::get('userlimit_default'));
3334
+    if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('userlimit_editable')) {
3335 3335
         $bbbsession['userlimit'] = intval($bbbsession['bigbluebuttonbn']->userlimit);
3336 3336
     }
3337 3337
     $bbbsession['voicebridge'] = $bbbsession['bigbluebuttonbn']->voicebridge;
@@ -3481,7 +3481,7 @@  discard block
 block discarded – undo
3481 3481
         'bbb-recording-tags' => bigbluebuttonbn_get_tags($bbbsession['cm']->id), // Same as $id.
3482 3482
     ];
3483 3483
     // Special metadata for recording processing.
3484
-    if ((boolean) \mod_bigbluebuttonbn\locallib\config::get('recordingstatus_enabled')) {
3484
+    if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recordingstatus_enabled')) {
3485 3485
         $metadata["bn-recording-status"] = json_encode(
3486 3486
             array(
3487 3487
                 'email' => array('"' . fullname($USER) . '" <' . $USER->email . '>'),
@@ -3489,10 +3489,10 @@  discard block
 block discarded – undo
3489 3489
             )
3490 3490
         );
3491 3491
     }
3492
-    if ((boolean) \mod_bigbluebuttonbn\locallib\config::get('recordingready_enabled')) {
3492
+    if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recordingready_enabled')) {
3493 3493
         $metadata['bn-recording-ready-url'] = $bbbsession['recordingReadyURL'];
3494 3494
     }
3495
-    if ((boolean) \mod_bigbluebuttonbn\locallib\config::get('meetingevents_enabled')) {
3495
+    if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('meetingevents_enabled')) {
3496 3496
         $metadata['analytics-callback-url'] = $bbbsession['meetingEventsURL'];
3497 3497
     }
3498 3498
     return $metadata;
Please login to merge, or discard this patch.