lib/billy/cache.rb in puffing-billy-0.6.2 vs lib/billy/cache.rb in puffing-billy-0.7.0

- old
+ new

@@ -78,10 +78,10 @@ else method + '_' + url.host + '_' + Digest::SHA1.hexdigest(scope.to_s + url.to_s) end body_msg = '' - if method == 'post' && !ignore_params && !merge_cached_response_key + if Billy.config.cache_request_body_methods.include?(method) && !ignore_params && !merge_cached_response_key body_formatted = JSONUtils.json?(body.to_s) ? JSONUtils.sort_json(body.to_s) : body.to_s body_msg = " with body '#{body_formatted}'" key += '_' + Digest::SHA1.hexdigest(body_formatted) end