Rename or inline local variables to avoid variable hiding

git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1571363 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Sebastian Bazley 2014-02-24 17:30:05 +00:00
parent 896fa04ce3
commit f18074b586
1 changed files with 4 additions and 5 deletions

View File

@ -85,17 +85,16 @@ class InternalHttpRequest extends AbstractHttpMessage implements HttpUriRequest,
@Override
public RequestLine getRequestLine() {
final String method = getMethod();
final ProtocolVersion ver = getProtocolVersion();
final URI uri = getURI();
final URI uriCopy = getURI();
String uritext = null;
if (uri != null) {
uritext = uri.toASCIIString();
if (uriCopy != null) {
uritext = uriCopy.toASCIIString();
}
if (uritext == null || uritext.isEmpty()) {
uritext = "/";
}
return new BasicRequestLine(method, uritext, ver);
return new BasicRequestLine(getMethod(), uritext, ver);
}