Commit 14bec929 authored by 技术部-任文超's avatar 技术部-任文超

追加Header参数容错代码

parent 8d4bda4e
......@@ -502,7 +502,7 @@ public class UserController implements IBaseController {
private User verificateUserNameAndPassword(HttpServletRequest request, String openId) {
String credential = request.getHeader("authorization");
if (!credential.startsWith("Basic ")) {
if (StringUtils.isBlank(credential) || !credential.startsWith("Basic ")) {
return null;
}
credential = credential.substring("Basic ".length(), credential.length());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment