public function UserAuthenticationController::logout in Drupal 10
Same name and namespace in other branches
- 8 core/modules/user/src/Controller/UserAuthenticationController.php \Drupal\user\Controller\UserAuthenticationController::logout()
- 9 core/modules/user/src/Controller/UserAuthenticationController.php \Drupal\user\Controller\UserAuthenticationController::logout()
Logs out a user.
Return value
\Symfony\Component\HttpFoundation\Response The response object.
1 string reference to 'UserAuthenticationController::logout'
- user.routing.yml in core/
modules/ user/ user.routing.yml - core/modules/user/user.routing.yml
File
- core/
modules/ user/ src/ Controller/ UserAuthenticationController.php, line 301
Class
- UserAuthenticationController
- Provides controllers for login, login status and logout via HTTP requests.
Namespace
Drupal\user\ControllerCode
public function logout() {
$this
->userLogout();
return new Response(NULL, 204);
}