|
@@ -52,6 +52,7 @@ public class UserContextInterceptor implements HandlerInterceptor {
|
|
|
response.setHeader("Content-Type", "application/json");
|
|
response.setHeader("Content-Type", "application/json");
|
|
|
response.setStatus(HttpStatus.UNAUTHORIZED.value());
|
|
response.setStatus(HttpStatus.UNAUTHORIZED.value());
|
|
|
JSONObject data = new JSONObject();
|
|
JSONObject data = new JSONObject();
|
|
|
|
|
+ data.put("state", "Fail");
|
|
|
data.put("message", ue.getMessage());
|
|
data.put("message", ue.getMessage());
|
|
|
response.getWriter().write(data.toString());
|
|
response.getWriter().write(data.toString());
|
|
|
response.getWriter().flush();
|
|
response.getWriter().flush();
|
|
@@ -76,6 +77,7 @@ public class UserContextInterceptor implements HandlerInterceptor {
|
|
|
response.setHeader("Content-Type", "application/json");
|
|
response.setHeader("Content-Type", "application/json");
|
|
|
response.setStatus(HttpStatus.UNAUTHORIZED.value());
|
|
response.setStatus(HttpStatus.UNAUTHORIZED.value());
|
|
|
JSONObject data = new JSONObject();
|
|
JSONObject data = new JSONObject();
|
|
|
|
|
+ data.put("state", "Fail");
|
|
|
data.put("message", "您访问资源(图片,文件,音频等)时,提供的验证code无效");
|
|
data.put("message", "您访问资源(图片,文件,音频等)时,提供的验证code无效");
|
|
|
response.getWriter().write(data.toJSONString());
|
|
response.getWriter().write(data.toJSONString());
|
|
|
response.getWriter().flush();
|
|
response.getWriter().flush();
|