lib/httpi/adapter/httpclient.rb in httpi-0.7.9 vs lib/httpi/adapter/httpclient.rb in httpi-0.8.0
- old
+ new
@@ -64,20 +64,20 @@
respond_with yield(request.url, request.headers, request.body)
end
def setup_client(request)
basic_setup request
- setup_http_auth request if request.auth.http?
+ setup_auth request if request.auth.http? || request.auth.ntlm?
setup_ssl_auth request.auth.ssl if request.auth.ssl?
end
def basic_setup(request)
client.proxy = request.proxy if request.proxy
client.connect_timeout = request.open_timeout if request.open_timeout
client.receive_timeout = request.read_timeout if request.read_timeout
end
- def setup_http_auth(request)
+ def setup_auth(request)
client.set_auth request.url, *request.auth.credentials
end
def setup_ssl_auth(ssl)
unless ssl.verify_mode == :none