mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-04-19 03:01:48 +08:00
去除默认的ACCEPT_LANGUAGE
This commit is contained in:
parent
c768831b53
commit
ae4600d0c7
@ -71,7 +71,8 @@ public enum GlobalHeaders {
|
||||
// 某些请求中这个自定义头会导致请求失败,此处采用与PostMan一致的默认头
|
||||
header(HeaderName.ACCEPT, "*/*", true);
|
||||
header(HeaderName.ACCEPT_ENCODING, "gzip, deflate", true);
|
||||
header(HeaderName.ACCEPT_LANGUAGE, "zh-CN,zh;q=0.8", true);
|
||||
// issue#3258,某些场景(如国外)不能指定中文
|
||||
//header(HeaderName.ACCEPT_LANGUAGE, "zh-CN,zh;q=0.8", true);
|
||||
// 此Header只有在post请求中有用,因此在HttpRequest的method方法中设置此头信息,此处去掉
|
||||
// header(Header.CONTENT_TYPE, ContentType.FORM_URLENCODED.toString(CharsetUtil.CHARSET_UTF_8), true);
|
||||
header(HeaderName.USER_AGENT, "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.142 Safari/537.36 Hutool", true);
|
||||
|
Loading…
x
Reference in New Issue
Block a user