2.0 release candidate (#3808)
* use SAML interface instead of implementation * moved implementation of SAML configs to system-configuration base class * bump composer packages * simplify configuration for different env
This commit is contained in:
@@ -17,6 +17,9 @@ use App\Security\RolePermissionManager;
|
||||
use Symfony\Component\Security\Core\Authentication\Token\TokenInterface;
|
||||
use Symfony\Component\Security\Core\Authorization\Voter\Voter;
|
||||
|
||||
/**
|
||||
* @extends Voter<string, Activity|Project|Customer|string>
|
||||
*/
|
||||
final class EntityMultiRoleVoter extends Voter
|
||||
{
|
||||
/**
|
||||
@@ -38,11 +41,6 @@ final class EntityMultiRoleVoter extends Voter
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $attribute
|
||||
* @param Activity|Project|Customer|string $subject
|
||||
* @return bool
|
||||
*/
|
||||
protected function supports(string $attribute, mixed $subject): bool
|
||||
{
|
||||
if (!\in_array($attribute, self::ALLOWED_ATTRIBUTES)) {
|
||||
@@ -60,12 +58,6 @@ final class EntityMultiRoleVoter extends Voter
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $attribute
|
||||
* @param Activity|Project|Customer|string $subject
|
||||
* @param TokenInterface $token
|
||||
* @return bool
|
||||
*/
|
||||
protected function voteOnAttribute(string $attribute, mixed $subject, TokenInterface $token): bool
|
||||
{
|
||||
$user = $token->getUser();
|
||||
|
||||
Reference in New Issue
Block a user