优化代码

This commit is contained in:
none
2023-03-21 14:59:10 +08:00
parent ad02bcad59
commit 57535a2ce7
3 changed files with 2 additions and 11 deletions

View File

@@ -68,7 +68,7 @@ public class LoginController {
@PostMapping("/logout")
public JsonResponse logout() throws JwtLogoutException {
jwtService.logout(RequestUtil.token(), SystemConstant.JWT_PRV_ADMIN_USER);
jwtService.adminUserLogout(RequestUtil.token());
return JsonResponse.success("success");
}

View File

@@ -70,7 +70,7 @@ public class LoginController {
@PostMapping("/logout")
public JsonResponse logout() throws JwtLogoutException {
jwtService.userLogout(PlayEduFCtx.getToken());
jwtService.userLogout(RequestUtil.token());
ctx.publishEvent(new UserLogoutEvent(this, PlayEduFCtx.getUserId(), PlayEduFCtx.getJwtJti()));
return JsonResponse.success();
}