Symfony\Component\Security\Http\RememberMe\AbstractRememberMeServices::loginSuccess PHP Method

loginSuccess() final public method

Implementation for RememberMeServicesInterface. This is called when an authentication is successful.
final public loginSuccess ( Request $request, Response $response, Symfony\Component\Security\Core\Authentication\Token\TokenInterface $token )
$request Symfony\Component\HttpFoundation\Request
$response Symfony\Component\HttpFoundation\Response
$token Symfony\Component\Security\Core\Authentication\Token\TokenInterface The token that resulted in a successful authentication
    final public function loginSuccess(Request $request, Response $response, TokenInterface $token)
    {
        if (!$token->getUser() instanceof UserInterface) {
            if (null !== $this->logger) {
                $this->logger->debug('Remember-me ignores token since it does not contain a UserInterface implementation.');
            }

            return;
        }

        if (!$this->isRememberMeRequested($request)) {
            if (null !== $this->logger) {
                $this->logger->debug('Remember-me was not requested.');
            }

            return;
        }

        if (null !== $this->logger) {
            $this->logger->debug('Remember-me was requested; setting cookie.');
        }

        $this->onLoginSuccess($request, $response, $token);
    }