update 登录鉴权修改
This commit is contained in:
@@ -66,6 +66,9 @@ public class LoginInterceptor implements HandlerInterceptor {
|
||||
*/
|
||||
private boolean isValidToken(String token) {
|
||||
System.out.println("token:"+token);
|
||||
if (token == null){
|
||||
throw new AuthException("用户未登录");
|
||||
}
|
||||
String userEmail = JwtUtils.getUserName(token);
|
||||
String getUserId = JwtUtils.getUserId(token);
|
||||
//1.把userEmail存入ThreadLocal 本地线程变量中
|
||||
|
||||
Reference in New Issue
Block a user