Skip to content

Commit 697da80

Browse files
Remove always true/false occurrences
1 parent c4652f9 commit 697da80

File tree

2 files changed

+0
-8
lines changed

2 files changed

+0
-8
lines changed

DependencyInjection/Compiler/ReplaceDecoratedRememberMeHandlerPass.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,6 @@ public function process(ContainerBuilder $container): void
3737

3838
// get the actual custom remember me handler definition (passed to the decorator)
3939
$realRememberMeHandler = $container->findDefinition((string) $definition->getArgument(0));
40-
if (null === $realRememberMeHandler) {
41-
throw new \LogicException(\sprintf('Invalid service definition for custom remember me handler; no service found with ID "%s".', (string) $definition->getArgument(0)));
42-
}
4340

4441
foreach ($rememberMeHandlerTags as $rememberMeHandlerTag) {
4542
// some custom handlers may be used on multiple firewalls in the same application

Tests/Functional/Bundle/SecuredPageBundle/Security/Core/User/ArrayUserProvider.php

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
namespace Symfony\Bundle\SecurityBundle\Tests\Functional\Bundle\SecuredPageBundle\Security\Core\User;
1313

1414
use Symfony\Bundle\SecurityBundle\Tests\Functional\UserWithoutEquatable;
15-
use Symfony\Component\Security\Core\Exception\UnsupportedUserException;
1615
use Symfony\Component\Security\Core\Exception\UserNotFoundException;
1716
use Symfony\Component\Security\Core\User\InMemoryUser;
1817
use Symfony\Component\Security\Core\User\UserInterface;
@@ -59,10 +58,6 @@ public function loadUserByIdentifier(string $identifier): UserInterface
5958

6059
public function refreshUser(UserInterface $user): UserInterface
6160
{
62-
if (!$user instanceof UserInterface) {
63-
throw new UnsupportedUserException(\sprintf('Instances of "%s" are not supported.', get_debug_type($user)));
64-
}
65-
6661
$storedUser = $this->getUser($user->getUserIdentifier());
6762
$class = $storedUser::class;
6863

0 commit comments

Comments
 (0)