lib/down/net_http.rb in down-4.3.0 vs lib/down/net_http.rb in down-4.4.0

- old
+ new

@@ -10,10 +10,15 @@ require "cgi" module Down class NetHttp < Backend def initialize(options = {}) - @options = { "User-Agent" => "Down/#{Down::VERSION}", max_redirects: 2 }.merge(options) + @options = { + "User-Agent" => "Down/#{Down::VERSION}", + max_redirects: 2, + open_timeout: 30, + read_timeout: 30, + }.merge(options) end def download(url, options = {}) options = @options.merge(options)