mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-05-09 23:51:34 +08:00
HttpRequest#get不再尝试File路径
This commit is contained in:
parent
aca181b229
commit
412ec8ae14
@ -138,11 +138,12 @@ public final class UrlBuilder implements Builder<String> {
|
||||
httpUrl = "http://" + httpUrl;
|
||||
}
|
||||
|
||||
return of(httpUrl, charset);
|
||||
return of(UrlUtil.toUrlForHttp(httpUrl), charset);
|
||||
}
|
||||
|
||||
/**
|
||||
* 使用URL字符串构建UrlBuilder,默认使用UTF-8编码
|
||||
* 使用URL字符串构建UrlBuilder,默认使用UTF-8编码<br>
|
||||
* 注意:此方法如果提供的URL为非网络协议,自动尝试使用文件协议
|
||||
*
|
||||
* @param url URL字符串
|
||||
* @return UrlBuilder
|
||||
|
Loading…
x
Reference in New Issue
Block a user