优化登录体验。修复因为流地址导致的录像服务无法识别

This commit is contained in:
648540858
2021-08-31 09:44:19 +08:00
parent 792c93694d
commit 3578c1c040
9 changed files with 38 additions and 9 deletions

View File

@@ -30,6 +30,9 @@ public class AnonymousAuthenticationEntryPoint implements AuthenticationEntryPoi
JSONObject jsonObject = new JSONObject();
jsonObject.put("code", "-1");
jsonObject.put("msg", "请登录后重新请求");
if (request.getRequestURI().contains("api/user/login")){
jsonObject.put("msg", e.getMessage());
}
response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);
try {
response.getWriter().print(jsonObject.toJSONString());