source: src/main/java/com/example/medweb/web/LogoutController.java

Last change on this file was e5fefbd, checked in by Anita Terziska <63020646+Nit4e@…>, 2 years ago

initial commit

  • Property mode set to 100644
File size: 394 bytes
Line 
1package com.example.medweb.web;
2
3
4import org.springframework.stereotype.Controller;
5import org.springframework.web.bind.annotation.GetMapping;
6
7import javax.servlet.http.HttpServletRequest;
8
9@Controller
10public class LogoutController {
11
12 @GetMapping("/logout")
13 public String logout (HttpServletRequest request) {
14 request.getSession().invalidate();
15 return "index";
16 }
17}
Note: See TracBrowser for help on using the repository browser.