Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugin: Refactor BBB to use new conference tables - refs #6153 #6161

Merged
merged 8 commits into from
Mar 25, 2025

Conversation

christianbeeznest
Copy link
Contributor

No description provided.

*/
public function update_course_field_in_all_courses($variable, $value)
public function update_course_field_in_all_courses($variable, $value): void
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Method name "BBBPlugin::update_course_field_in_all_courses" is not in camel caps format

->setTitle($params['meeting_name'] ?? $this->getCurrentVideoConferenceName())
->setAttendeePw($attendeePassword)
->setModeratorPw($moderatorPassword)
->setRecord((bool)$params['record'])
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A cast statement must be followed by a single space

Event::addEvent(
'bbb_create_meeting',
'meeting_id',
(int)$id,
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A cast statement must be followed by a single space

}

$finalMeetingUrl = $this->joinMeeting($meetingName, true);
return $finalMeetingUrl;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing blank line before return statement


$entity = $result[0];

return [
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar blocks of code found in 2 locations. Consider refactoring.

}

return [];
return [
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar blocks of code found in 2 locations. Consider refactoring.

@@ -723,20 +716,40 @@ public function getMeetingInfo($params)
*
* @return array
*/
public function getMeetingParticipantInfo($meetingId, $userId)
public function getMeetingParticipantInfo($meetingId, $userId): array
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Method getMeetingParticipantInfo has 28 lines of code (exceeds 25 allowed). Consider refactoring.

->execute();
}

public function findOneArrayByMeetingAndParticipant(int $meetingId, int $participantId): ?array
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Method findOneArrayByMeetingAndParticipant has 27 lines of code (exceeds 25 allowed). Consider refactoring.

];
}

public function getMeetingsLight(
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function getMeetingsLight has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.

Copy link

codeclimate bot commented Mar 25, 2025

Code Climate has analyzed commit cce0dda and detected 16 issues on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 8
Duplication 8

View more on Code Climate.

@christianbeeznest christianbeeznest merged commit 7614239 into chamilo:master Mar 25, 2025
1 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants