未验证 提交 60b484ce 编写于 作者: R runzexia

do not return 401

上级 cd739022
......@@ -177,6 +177,9 @@ func Validate(req *restful.Request, resp *restful.Response) {
}
resp.Header().Set(restful.HEADER_ContentType, restful.MIME_JSON)
if resp.StatusCode() == http.StatusUnauthorized {
resp.WriteHeader(http.StatusPreconditionRequired)
}
resp.Write(res)
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册