瀏覽代碼

退出方法修改

RuoYi 6 年之前
父節點
當前提交
8b4d3cecb4
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/main/java/com/ruoyi/framework/shiro/web/filter/LogoutFilter.java

+ 1 - 1
src/main/java/com/ruoyi/framework/shiro/web/filter/LogoutFilter.java

@@ -46,7 +46,7 @@ public class LogoutFilter extends org.apache.shiro.web.filter.authc.LogoutFilter
             String redirectUrl = getRedirectUrl(request, response, subject);
             try
             {
-                User user = (User) ShiroUtils.getSubjct().getPrincipal();
+                User user = ShiroUtils.getUser();
                 if (StringUtils.isNotNull(user))
                 {
                     String loginName = user.getLoginName();