From a72a529ca1c4987c339caa2042b4f8add1d03f54 Mon Sep 17 00:00:00 2001 From: Beth Skurrie Date: Tue, 29 Aug 2023 13:37:39 +1000 Subject: [PATCH] feat: do not accept gzip responses when VERBOSE=true As it makes it very hard to debug --- lib/pact_broker/client/hal/http_client.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/pact_broker/client/hal/http_client.rb b/lib/pact_broker/client/hal/http_client.rb index b7972a9..4e5fd50 100644 --- a/lib/pact_broker/client/hal/http_client.rb +++ b/lib/pact_broker/client/hal/http_client.rb @@ -50,6 +50,7 @@ def create_request uri, http_method, body = nil, headers = {} request['Content-Type'] ||= "application/json" if ['Post', 'Put'].include?(http_method) request['Content-Type'] ||= "application/merge-patch+json" if ['Patch'].include?(http_method) request['Accept'] = "application/hal+json" + request['Accept-Encoding'] = nil if verbose? headers.each do | key, value | request[key] = value end