Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions src/Controller/Logout.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
use EcPhp\CasLib\Contract\CasInterface;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use Symfony\Bundle\SecurityBundle\Security;
use Symfony\Component\HttpFoundation\RedirectResponse;
use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface;
use Throwable;
Expand All @@ -24,7 +23,6 @@ final class Logout
public function __invoke(
ServerRequestInterface $request,
CasInterface $cas,
Security $security,
TokenStorageInterface $tokenStorage
): RedirectResponse|ResponseInterface {
try {
Expand All @@ -36,7 +34,6 @@ public function __invoke(
return new RedirectResponse('/');
}

$security->getToken()?->eraseCredentials();
$tokenStorage->setToken(null);

return $response;
Expand Down
2 changes: 0 additions & 2 deletions src/Security/Core/User/CasUser.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ public function __toString(): string
return (string) $this->get('user');
}

public function eraseCredentials(): void {}

public function get(string $key, mixed $default = null): mixed
{
return $this->payload[$key] ?? $default;
Expand Down