|
|
@@ -28,7 +28,6 @@ public class TokenInterceptor implements HandlerInterceptor {
|
|
|
} else {
|
|
|
String userId = redisUtil.get("USER_TOKEN_" + token);
|
|
|
String roleId = redisUtil.get("USER_ROLE_" + token);
|
|
|
- List<String> userPerm = redisUtil.lGetAll("USER_PERM_" + token);
|
|
|
if (userId == null || roleId == null) { // token无效
|
|
|
throw new WebException(ResultCode.USER_INVALID_TOKEN);
|
|
|
}
|
|
|
@@ -38,6 +37,8 @@ public class TokenInterceptor implements HandlerInterceptor {
|
|
|
throw new WebException(ResultCode.USER_INVALID_TOKEN);
|
|
|
}
|
|
|
|
|
|
+ List<String> userPerm = redisUtil.lGetAll("USER_PERM_" + token);
|
|
|
+
|
|
|
// redis字符串类型转long
|
|
|
List<Long> userPermLong = new ArrayList<>();
|
|
|
for (String str : userPerm) {
|