Project

General

Profile

Revision b20500a9

Added by Thomas McKay almost 2 years ago

fixes #24370 - don't log binary upload contents

View differences:

lib/runcible/base.rb
30 30
    end
31 31

  
32 32
    # rubocop:disable Metrics/AbcSize:
33
    # rubocop:disable PerceivedComplexity
33 34
    def call(method, path, options = {})
34 35
      self.logs = []
35 36
      clone_config = self.config.clone
......
67 68
      args = [method]
68 69
      args << generate_payload(options) if [:post, :put].include?(method)
69 70
      args << headers
71
      starting_arg = options[:no_log_payload] == true ? 2 : 1
72
      self.logs << ([method.upcase, URI.join(client.url, path)] + args[starting_arg..-1]).join(': ')
70 73

  
71
      self.logs << ([method.upcase, URI.join(client.url, path)] + args[1..-1]).join(': ')
72 74
      response = get_response(client, path, *args)
73 75
      processed = process_response(response)
74 76
      self.logs << "Response: #{response.code}: #{response.body}"

Also available in: Unified diff