We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 76a150c commit 4669c7dCopy full SHA for 4669c7d
src/main/java/com/ning/http/client/RequestBuilderBase.java
@@ -75,8 +75,9 @@ public RequestImpl(boolean useRawUrl) {
75
public RequestImpl(Request prototype) {
76
if (prototype != null) {
77
this.method = prototype.getMethod();
78
- int pos = prototype.getUrl().indexOf("?");
79
- this.url = pos > 0 ? prototype.getUrl().substring(0, pos) : prototype.getUrl();
+ String prototypeUrl = prototype.getUrl();
+ int pos = prototypeUrl.indexOf("?");
80
+ this.url = pos > 0 ? prototypeUrl.substring(0, pos) : prototypeUrl;
81
this.address = prototype.getInetAddress();
82
this.localAddress = prototype.getLocalAddress();
83
this.headers = new FluentCaseInsensitiveStringsMap(prototype.getHeaders());
0 commit comments