Update doctrine orm to v4

This commit is contained in:
Tim
2025-07-20 15:43:28 +02:00
parent f7282ae31a
commit 94bf0075f0
5 changed files with 51 additions and 255 deletions

View File

@ -4,13 +4,14 @@ namespace App\Security\Voter;
use App\Entity\Snip;
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;
class SnipVoter extends Voter
{
public const EDIT = 'edit';
public const VIEW = 'view';
public const string EDIT = 'edit';
public const string VIEW = 'view';
protected function supports(string $attribute, mixed $subject): bool
{
@ -20,7 +21,7 @@ class SnipVoter extends Voter
&& $subject instanceof Snip;
}
protected function voteOnAttribute(string $attribute, mixed $subject, TokenInterface $token): bool
protected function voteOnAttribute(string $attribute, mixed $subject, TokenInterface $token,/* , ?Vote $vote = null */): bool
{
/** @var Snip $subject */