Skip to content

Commit

Permalink
Aligned RepositoryUserAuthenticationSubscriber with Symfony 6
Browse files Browse the repository at this point in the history
  • Loading branch information
alongosz committed Oct 31, 2024
1 parent 1abf9cf commit df912c9
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
use Psr\Log\NullLogger;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Symfony\Component\HttpFoundation\RequestStack;
use Symfony\Component\Security\Core\User\PasswordAuthenticatedUserInterface;
use Symfony\Component\Security\Http\Authenticator\Passport\Badge\UserBadge;
use Symfony\Component\Security\Http\Authenticator\Passport\SelfValidatingPassport;
use Symfony\Component\Security\Http\Event\CheckPassportEvent;
Expand Down Expand Up @@ -66,7 +67,7 @@ public function validateRepositoryUser(CheckPassportEvent $event): void
}

$user = $badge->getUser();
if (!$user instanceof IbexaUserInterface) {
if (!$user instanceof IbexaUserInterface || !$user instanceof PasswordAuthenticatedUserInterface) {
return;
}

Expand Down

0 comments on commit df912c9

Please sign in to comment.