Require zlib for Ruby 1.8

In Ruby 1.9, zlib is required by net/http but this is not the case in
Ruby 1.8, causing a NameError (uninitialized constant
Faraday::Adapter::NetHttp::Zlib).
This commit is contained in:
Erik Michaels-Ober 2012-08-15 11:17:15 -04:00
parent e15b51b3bb
commit 48ff65b764

View File

@ -4,6 +4,7 @@ rescue LoadError
warn "Warning: no such file to load -- net/https. Make sure openssl is installed if you want ssl support"
require 'net/http'
end
require 'zlib'
module Faraday
class Adapter