提交 44eaf2e9 编写于 作者: F fengyw

优化

上级 3e3264af
......@@ -123,7 +123,7 @@ public class EduGlobalFilter implements GlobalFilter, Ordered {
private Long getUserId(ServerHttpRequest request) {
// 头部
String token = request.getHeaders().getFirst(Constants.TOKEN);
if (StringUtils.isEmpty(token)) {
if (!StringUtils.hasText(token)) {
throw new BaseException("token不存在,请重新登录");
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册