完善登出功能,记录日志

pull/2/head
asas6559 2021-03-08 22:34:39 +08:00
parent d5ac6e7a19
commit 4294ed2548
1 changed files with 3 additions and 1 deletions

View File

@ -162,7 +162,9 @@ public class SysAuthServiceImpl implements SysAuthService {
public void logout(String token) {
// 查询用户信息
LoginUser loginUser = userSessionService.getLoginUser(token);
if(loginUser == null) return;
if(loginUser == null) {
return;
}
// 删除session
userSessionService.deleteUserSession(token);
this.createLogoutLog(loginUser.getUsername(), SysLoginResultEnum.SUCCESS);