Class: Whisperer::Preprocessors::ContentLength

Inherits:
Base
  • Object
show all
Defined in:
lib/whisperer/preprocessors/content_length.rb

Instance Method Summary collapse

Methods inherited from Base

#initialize

Methods included from Helpers

#add_builder

Constructor Details

This class inherits a constructor from Whisperer::Preprocessors::Base

Instance Method Details

#processObject



8
9
10
11
12
13
14
# File 'lib/whisperer/preprocessors/content_length.rb', line 8

def process
  headers = @record.response.headers

  if headers.content_length.nil?
    headers.content_length = @record.response.body.string.size
  end
end