change variable name request to client
parent
224a4f9456
commit
3abd4be785
|
@ -21,13 +21,13 @@ module MechanizeCr
|
||||||
end
|
end
|
||||||
|
|
||||||
def http_request(uri, method, params)
|
def http_request(uri, method, params)
|
||||||
request = ::HTTP::Client.new(uri.host.not_nil!)
|
client = ::HTTP::Client.new(uri.host.not_nil!)
|
||||||
path = compose_path(uri, params)
|
path = compose_path(uri, params)
|
||||||
case uri.scheme.not_nil!.downcase
|
case uri.scheme.not_nil!.downcase
|
||||||
when "http", "https" then
|
when "http", "https" then
|
||||||
case method
|
case method
|
||||||
when :get
|
when :get
|
||||||
request.get(path, headers: request_headers)
|
client.get(path, headers: request_headers)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue