lib/onebox/status_check.rb in onebox-2.2.2 vs lib/onebox/status_check.rb in onebox-2.2.4

- old
+ new

@@ -33,10 +33,10 @@ end private def check - res = open(@url, read_timeout: (@options.timeout || Onebox.options.timeout)) + res = URI.open(@url, read_timeout: (@options.timeout || Onebox.options.timeout)) @status = res.status.first.to_i rescue OpenURI::HTTPError => e @status = e.io.status.first.to_i rescue Timeout::Error, Errno::ECONNREFUSED, Net::HTTPError @status = 0