lib/gillbus.rb in gillbus-0.18.1 vs lib/gillbus.rb in gillbus-0.18.2

- old
+ new

@@ -23,10 +23,12 @@ def self.register(klass, method_name) define_method method_name do |*args| request_class = klass::Request response_class = klass::Response request = request_class.new(*args) - headers = { 'Cookie' => "JSESSIONID=#{session_id}" } if session_id + headers = {} + headers['Cookie'] = "JSESSIONID=#{session_id}" if session_id + headers['Accept-Encoding'] = 'gzip' request_time_start = Time.now http_response = driver.public_send(request.method, request.path, request.params, headers) request_time_end = Time.now result = response_class.parse_string(http_response.body.force_encoding('utf-8'), timezone: timezone) cookie_string = http_response.headers['Set-Cookie']