diff --git a/plugin/bbb/lib/bbb.lib.php b/plugin/bbb/lib/bbb.lib.php index f112671502..b064e56169 100755 --- a/plugin/bbb/lib/bbb.lib.php +++ b/plugin/bbb/lib/bbb.lib.php @@ -579,7 +579,7 @@ class bbb } } - if (strval($meetingIsRunningInfo['returncode']) == 'SUCCESS' && + if (strval($meetingIsRunningInfo['returncode']) === 'SUCCESS' && isset($meetingIsRunningInfo['meetingName']) && !empty($meetingIsRunningInfo['meetingName']) ) { @@ -1140,7 +1140,7 @@ class bbb // Check if there are recordings for this meeting $recordings = $this->api->getRecordings(['meetingId' => $meetingData['remote_id']]); - if (!empty($recordings) && isset($recordings['messageKey']) && $recordings['messageKey'] == 'noRecordings') { + if (!empty($recordings) && isset($recordings['messageKey']) && $recordings['messageKey'] === 'noRecordings') { return false; } else { if (!empty($recordings['records'])) { diff --git a/plugin/bbb/lib/bbb_api.php b/plugin/bbb/lib/bbb_api.php index 82decef55f..a8f10856a5 100755 --- a/plugin/bbb/lib/bbb_api.php +++ b/plugin/bbb/lib/bbb_api.php @@ -647,6 +647,10 @@ class BigBlueButtonBN { */ public function generateRecording($recordingParams) { + if (empty($recordingParams)) { + return false; + } + $recordingsUrl = $this->_bbbServerBaseUrl.'../demo/regenerateRecord.jsp?'; $params = 'recordID='.urlencode($recordingParams['recordId']); $url = $recordingsUrl.$params.'&checksum='.sha1('regenerateRecord'.$params.$this->_securitySalt); @@ -662,4 +666,4 @@ class BigBlueButtonBN { return true; } -} \ No newline at end of file +} diff --git a/plugin/bbb/listing.php b/plugin/bbb/listing.php index efc1324099..7241b2bc7b 100755 --- a/plugin/bbb/listing.php +++ b/plugin/bbb/listing.php @@ -67,13 +67,16 @@ if ($conferenceManager) { api_not_allowed(); } $result = $bbb->regenerateRecording($_GET['id'], $_GET['record_id']); + if ($result) { $message = Display::return_message(get_lang('Success'), 'success'); } else { $message = Display::return_message(get_lang('Error'), 'error'); } + Display::addFlash($message); header('Location: '.$bbb->getListingUrl()); + exit; break; case 'delete_record': $result = $bbb->deleteRecording($_GET['id']); @@ -150,7 +153,6 @@ if (($meetingExists || $userCanSeeJoinButton) && ($maxUsers == 0 || $maxUsers > $showJoinButton = true; } $conferenceUrl = $bbb->getConferenceUrl(); - $courseInfo = api_get_course_info(); $formToString = ''; @@ -161,7 +163,7 @@ if ($bbb->isGlobalConference() === false && ) { $url = api_get_self().'?'.api_get_cidreq(true, false).'&gidReq='; $htmlHeadXtra[] = '