mirror of
https://gitee.com/dromara/RuoYi-Cloud-Plus.git
synced 2025-09-02 10:36:40 +00:00
fix 修复 token 过期登出无法清理在线用户问题
This commit is contained in:
@@ -108,9 +108,13 @@ public class SysLoginService {
|
||||
public void logout() {
|
||||
try {
|
||||
LoginUser loginUser = LoginHelper.getLoginUser();
|
||||
StpUtil.logout();
|
||||
recordLogininfor(loginUser.getUsername(), Constants.LOGOUT, MessageUtils.message("user.logout.success"));
|
||||
} catch (NotLoginException ignored) {
|
||||
} finally {
|
||||
try {
|
||||
StpUtil.logout();
|
||||
} catch (NotLoginException ignored) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user