feat: upgrade to symfony 7.4
This commit is contained in:
@@ -5,6 +5,7 @@ namespace App\Security\Voter;
|
||||
use App\Entity\User;
|
||||
use Symfony\Bundle\SecurityBundle\Security;
|
||||
use Symfony\Component\Security\Core\Authentication\Token\TokenInterface;
|
||||
use Symfony\Component\Security\Core\Authorization\Voter\Vote;
|
||||
use Symfony\Component\Security\Core\Authorization\Voter\Voter;
|
||||
use Symfony\Component\Security\Core\User\UserInterface;
|
||||
|
||||
@@ -19,7 +20,7 @@ class ImpersonationVoter extends Voter
|
||||
return 'CAN_IMPERSONATE' === $attribute && $subject instanceof UserInterface;
|
||||
}
|
||||
|
||||
protected function voteOnAttribute(string $attribute, mixed $subject, TokenInterface $token): bool
|
||||
protected function voteOnAttribute(string $attribute, mixed $subject, TokenInterface $token, ?Vote $vote = null): bool
|
||||
{
|
||||
$currentUser = $token->getUser();
|
||||
$targetUser = $subject;
|
||||
|
||||
Reference in New Issue
Block a user