Sha256: 1aa75e23b6fb62774888005e7410d8d4cdb02b7c237f06c39211dd4a678ef0a6
Contents?: true
Size: 472 Bytes
Versions: 8
Compression:
Stored size: 472 Bytes
Contents
require 'faraday_middleware/response_middleware' module ZendeskAPI module Middleware module Response # Faraday middleware to handle content-encoding = gzip class Gzip < FaradayMiddleware::ResponseMiddleware define_parser do |body| Zlib::GzipReader.new(StringIO.new(body)).read end def parse_response?(env) super && env[:response_headers]['content-encoding'] == "gzip" end end end end end
Version data entries
8 entries across 8 versions & 1 rubygems