Completed
Push — 1.10.x ( f2fc06...a47b7a )
by
unknown
50:55
created
plugin/bbb/lib/bbb_plugin.class.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
     }
43 43
 
44 44
     /**
45
-     * @return BBBPlugin|null
45
+     * @return BBBPlugin
46 46
      */
47 47
     public static function create()
48 48
     {
Please login to merge, or discard this patch.
plugin/bbb/lib/bbb.lib.php 1 patch
Spacing   +31 added lines, -31 removed lines patch added patch discarded remove patch
@@ -138,13 +138,13 @@  discard block
 block discarded – undo
138 138
         $params['session_id'] = api_get_session_id();
139 139
 
140 140
         $params['attendee_pw'] = isset($params['moderator_pw']) ? $params['moderator_pw'] : $courseCode;
141
-        $attendeePassword =  $params['attendee_pw'];
141
+        $attendeePassword = $params['attendee_pw'];
142 142
         $params['moderator_pw'] = isset($params['moderator_pw']) ? $params['moderator_pw'] : $this->getModMeetingPassword();
143 143
         $moderatorPassword = $params['moderator_pw'];
144 144
 
145 145
         $params['record'] = api_get_course_setting('big_blue_button_record_and_store', $courseCode) == 1 ? true : false;
146 146
         $max = api_get_course_setting('big_blue_button_max_students_allowed', $courseCode);
147
-        $max =  isset($max) ? $max : -1;
147
+        $max = isset($max) ? $max : -1;
148 148
 
149 149
         $params['status'] = 1;
150 150
         // Generate a pseudo-global-unique-id to avoid clash of conferences on
@@ -175,23 +175,23 @@  discard block
 block discarded – undo
175 175
             $duration = 300;
176 176
 
177 177
             $bbbParams = array(
178
-                'meetingId' => $params['remote_id'], 					// REQUIRED
179
-                'meetingName' => $meetingName, 	// REQUIRED
180
-                'attendeePw' => $attendeePassword, 					// Match this value in getJoinMeetingURL() to join as attendee.
181
-                'moderatorPw' => $moderatorPassword, 					// Match this value in getJoinMeetingURL() to join as moderator.
182
-                'welcomeMsg' => $welcomeMessage, 					// ''= use default. Change to customize.
183
-                'dialNumber' => '', 					// The main number to call into. Optional.
184
-                'voiceBridge' => $params['voice_bridge'], 					// PIN to join voice. Required.
185
-                'webVoice' => '', 						// Alphanumeric to join voice. Optional.
178
+                'meetingId' => $params['remote_id'], // REQUIRED
179
+                'meetingName' => $meetingName, // REQUIRED
180
+                'attendeePw' => $attendeePassword, // Match this value in getJoinMeetingURL() to join as attendee.
181
+                'moderatorPw' => $moderatorPassword, // Match this value in getJoinMeetingURL() to join as moderator.
182
+                'welcomeMsg' => $welcomeMessage, // ''= use default. Change to customize.
183
+                'dialNumber' => '', // The main number to call into. Optional.
184
+                'voiceBridge' => $params['voice_bridge'], // PIN to join voice. Required.
185
+                'webVoice' => '', // Alphanumeric to join voice. Optional.
186 186
                 'logoutUrl' =>  $this->logoutUrl,
187
-                'maxParticipants' => $max, 				// Optional. -1 = unlimitted. Not supported in BBB. [number]
188
-                'record' => $record, 					// New. 'true' will tell BBB to record the meeting.
189
-                'duration' => $duration, 				// Default = 0 which means no set duration in minutes. [number]
187
+                'maxParticipants' => $max, // Optional. -1 = unlimitted. Not supported in BBB. [number]
188
+                'record' => $record, // New. 'true' will tell BBB to record the meeting.
189
+                'duration' => $duration, // Default = 0 which means no set duration in minutes. [number]
190 190
                 //'meta_category' => '', 				// Use to pass additional info to BBB server. See API docs.
191 191
             );
192 192
 
193 193
             if ($this->debug) {
194
-                error_log("create_meeting params: ".print_r($bbbParams,1));
194
+                error_log("create_meeting params: ".print_r($bbbParams, 1));
195 195
             }
196 196
 
197 197
             $status = false;
@@ -204,7 +204,7 @@  discard block
 block discarded – undo
204 204
                 if (isset($result) && strval($result['returncode']) == 'SUCCESS') {
205 205
                     if ($this->debug) {
206 206
                         error_log(
207
-                            "create_meeting result: " . print_r($result, 1)
207
+                            "create_meeting result: ".print_r($result, 1)
208 208
                         );
209 209
                     }
210 210
                     $meeting = $this->joinMeeting($meetingName, true);
@@ -327,7 +327,7 @@  discard block
 block discarded – undo
327 327
 
328 328
             if ($this->debug) {
329 329
                 error_log(
330
-                    "meeting is running: " . intval($meetingInfoExists)
330
+                    "meeting is running: ".intval($meetingInfoExists)
331 331
                 );
332 332
             }
333 333
 
@@ -344,11 +344,11 @@  discard block
 block discarded – undo
344 344
 
345 345
         if ($meetingInfoExists) {
346 346
             $joinParams = array(
347
-                'meetingId' => $meetingData['remote_id'],	//	-- REQUIRED - A unique id for the meeting
348
-                'username' => $this->user_complete_name,	//-- REQUIRED - The name that will display for the user in the meeting
349
-                'password' => $pass,			//-- REQUIRED - The attendee or moderator password, depending on what's passed here
347
+                'meetingId' => $meetingData['remote_id'], //	-- REQUIRED - A unique id for the meeting
348
+                'username' => $this->user_complete_name, //-- REQUIRED - The name that will display for the user in the meeting
349
+                'password' => $pass, //-- REQUIRED - The attendee or moderator password, depending on what's passed here
350 350
                 //'createTime' => api_get_utc_datetime(),			//-- OPTIONAL - string. Leave blank ('') unless you set this correctly.
351
-                'userID' => api_get_user_id(),				//-- OPTIONAL - string
351
+                'userID' => api_get_user_id(), //-- OPTIONAL - string
352 352
                 'webVoiceConf' => ''	//	-- OPTIONAL - string
353 353
             );
354 354
             $url = $this->api->getJoinMeetingURL($joinParams);
@@ -357,7 +357,7 @@  discard block
 block discarded – undo
357 357
             $url = $this->logoutUrl;
358 358
         }
359 359
         if ($this->debug) {
360
-            error_log("return url :" . $url);
360
+            error_log("return url :".$url);
361 361
         }
362 362
 
363 363
         return $url;
@@ -430,7 +430,7 @@  discard block
 block discarded – undo
430 430
             }
431 431
             $meetingBBB['end_url'] = $this->endUrl($meetingDB);
432 432
 
433
-            if ((string)$meetingBBB['returncode'] == 'FAILED') {
433
+            if ((string) $meetingBBB['returncode'] == 'FAILED') {
434 434
                 if ($meetingDB['status'] == 1 && $this->isConferenceManager()) {
435 435
                     $this->endMeeting($meetingDB['id']);
436 436
                 }
@@ -600,7 +600,7 @@  discard block
 block discarded – undo
600 600
                     $item['action_links'] = implode('<br />', $actionLinksArray);
601 601
                 }
602 602
                 //var_dump($recordArray);
603
-                $item['show_links']  = implode('<br />', $recordArray);
603
+                $item['show_links'] = implode('<br />', $recordArray);
604 604
                 $item['action_links'] = implode('<br />', $actionLinksArray);
605 605
             }
606 606
 
@@ -613,11 +613,11 @@  discard block
 block discarded – undo
613 613
 
614 614
             if ($meetingDB['status'] == 1) {
615 615
                 $joinParams = array(
616
-                    'meetingId' => $meetingDB['remote_id'],		//-- REQUIRED - A unique id for the meeting
617
-                    'username' => $this->user_complete_name,	//-- REQUIRED - The name that will display for the user in the meeting
618
-                    'password' => $pass,			//-- REQUIRED - The attendee or moderator password, depending on what's passed here
619
-                    'createTime' => '',			//-- OPTIONAL - string. Leave blank ('') unless you set this correctly.
620
-                    'userID' => '',			//	-- OPTIONAL - string
616
+                    'meetingId' => $meetingDB['remote_id'], //-- REQUIRED - A unique id for the meeting
617
+                    'username' => $this->user_complete_name, //-- REQUIRED - The name that will display for the user in the meeting
618
+                    'password' => $pass, //-- REQUIRED - The attendee or moderator password, depending on what's passed here
619
+                    'createTime' => '', //-- OPTIONAL - string. Leave blank ('') unless you set this correctly.
620
+                    'userID' => '', //	-- OPTIONAL - string
621 621
                     'webVoiceConf' => ''	//	-- OPTIONAL - string
622 622
                 );
623 623
                 $item['go_url'] = $this->protocol.$this->api->getJoinMeetingURL($joinParams);
@@ -678,8 +678,8 @@  discard block
 block discarded – undo
678 678
         $pass = $this->getUserMeetingPassword();
679 679
 
680 680
         $endParams = array(
681
-            'meetingId' => $meetingData['remote_id'],   // REQUIRED - We have to know which meeting to end.
682
-            'password' => $pass,        // REQUIRED - Must match moderator pass for meeting.
681
+            'meetingId' => $meetingData['remote_id'], // REQUIRED - We have to know which meeting to end.
682
+            'password' => $pass, // REQUIRED - Must match moderator pass for meeting.
683 683
         );
684 684
         $this->api->endMeetingWithXmlResponseArray($endParams);
685 685
         Database::update(
@@ -881,7 +881,7 @@  discard block
 block discarded – undo
881 881
      */
882 882
     public function redirectToBBB($url)
883 883
     {
884
-        if (file_exists(__DIR__ . '/../config.vm.php')) {
884
+        if (file_exists(__DIR__.'/../config.vm.php')) {
885 885
             // Using VM
886 886
             echo Display::url(get_lang('ClickToContinue'), $url);
887 887
             exit;
Please login to merge, or discard this patch.