Skip to content

Commit

Permalink
Task techjoomla#24 chore: Modified the Authorised and Check methods i…
Browse files Browse the repository at this point in the history
…n RBACL
  • Loading branch information
pravinTek committed Mar 3, 2020
1 parent a51edc6 commit 2379acd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/administrator/includes/rbacl.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public static function check($userId, $client, $action, $actionClient = null, $c
$userModel = self::model("user");
$contentRoleId = $userModel->getAssociatedContentRole($userId, $client, $contentId);

if (in_array($contentRoleId[0], $allowedRoles))
if (!empty(array_intersect($contentRoleId, $allowedRoles)))
{
return true;
}
Expand Down

0 comments on commit 2379acd

Please sign in to comment.