W3cubDocs

/Symfony 4.1

CsrfTokenClearingLogoutHandler

class CsrfTokenClearingLogoutHandler implements LogoutHandlerInterface

Methods

__construct(ClearableTokenStorageInterface $csrfTokenStorage)
logout(Request $request, Response $response, TokenInterface $token)

This method is called by the LogoutListener when a user has requested to be logged out. Usually, you would unset session variables, or remove cookies, etc.

Details

__construct(ClearableTokenStorageInterface $csrfTokenStorage)

Parameters

ClearableTokenStorageInterface $csrfTokenStorage

logout(Request $request, Response $response, TokenInterface $token)

This method is called by the LogoutListener when a user has requested to be logged out. Usually, you would unset session variables, or remove cookies, etc.

Parameters

Request $request
Response $response
TokenInterface $token