File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
src/main/java/net/coderic/core/api/controllers Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 9
9
import org .springframework .web .bind .annotation .GetMapping ;
10
10
import org .springframework .web .bind .annotation .RestController ;
11
11
12
+ import java .security .Principal ;
13
+
12
14
@ RestController
13
15
public class HelloController {
14
16
SecurityContextLogoutHandler logoutHandler = new SecurityContextLogoutHandler ();
15
17
@ GetMapping ("/user" )
16
- public ResponseEntity <OAuth2User > getUser (@ AuthenticationPrincipal OAuth2User principal ) {
17
- return new ResponseEntity <OAuth2User >(principal , HttpStatus .OK );
18
+ public ResponseEntity <Principal > getUser (@ AuthenticationPrincipal Principal principal ) {
19
+ return new ResponseEntity <Principal >(principal , HttpStatus .OK );
18
20
}
19
21
/*
20
22
@GetMapping("/logout")
You can’t perform that action at this time.
0 commit comments