We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent db7aaa4 commit 85ecba7Copy full SHA for 85ecba7
lib/convert_api/client.rb
@@ -91,10 +91,10 @@ def handle_http_exceptions
91
raise(TimeoutError, e)
92
end
93
94
- def http(read_timeout: nil)
+ def http(options = {})
95
http = Net::HTTP.new(base_uri.host, base_uri.port)
96
http.open_timeout = config.connect_timeout
97
- http.read_timeout = read_timeout || config.read_timeout
+ http.read_timeout = options.fetch(:read_timeout, config.read_timeout)
98
http.use_ssl = base_uri.scheme == 'https'
99
# http.set_debug_output $stderr
100
http
0 commit comments