Removed unnecessarily duplicated code from HTTPRequest.getUrl .