|
|
@@ -94,6 +94,10 @@ public class UserContextInterceptor implements HandlerInterceptor {
|
|
|
response.setStatus(HttpStatus.UNAUTHORIZED.value());
|
|
|
JSONObject data = new JSONObject();
|
|
|
data.put("message", "用户没有登录,请登录");
|
|
|
+ JSONObject exception = new JSONObject();
|
|
|
+ exception.put("type", "AuthenticationCredentialsNotFoundException");
|
|
|
+ data.put("state", "Fail");
|
|
|
+ data.put("exception", exception);
|
|
|
response.getWriter().write(data.toJSONString());
|
|
|
response.getWriter().flush();
|
|
|
response.getWriter().close();
|