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

Save extended status on user entry object + fix filtering logic to us… #13120

Merged
merged 2 commits into from
Feb 5, 2025

Conversation

yossipapi
Copy link
Collaborator

…e bitmask and operation

@@ -45,4 +56,22 @@ public function setPermissionOrder($permissionOrder)
{
$this->putInCustomData(self::CUSTOM_DATA_PERMISSION_ORDER, $permissionOrder);
}

public function syncExtendedStatus($permissionLevels)
Copy link
Collaborator

Choose a reason for hiding this comment

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

protected


public function syncExtendedStatus($permissionLevels)
{
if (!$permissionLevels || !count($permissionLevels))
Copy link
Collaborator

Choose a reason for hiding this comment

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

remove

foreach ($this->permissionLevels as $permissionLevel)
{
/** @var KalturaPermissionLevel $permissionLevel */
$val = $permissionLevel->permissionLevel;
$this->permissionLevelsBitmask += $permissionBitmask[intval($val)];
$permissionLevelsBitmask += PermissionLevelUserEntry::$permissionLevelBitmask[intval($val)];
Copy link
Collaborator

Choose a reason for hiding this comment

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

check that value exist in array before taking its values

@drorsou drorsou merged commit 8f680fd into Ursa-21.9.0 Feb 5, 2025
@drorsou drorsou deleted the Ursa-21.9.0-PLAT-25073-1 branch February 5, 2025 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants