class Aws::LexModelsV2::Plugins::ContentType::Handler

Public Instance Methods

call(context) click to toggle source
# File lib/aws-sdk-lexmodelsv2/plugins/content_type.rb, line 13
def call(context)
  # Some operations break when given an empty content-type header.
  # The SDK adds this blank content-type header
  # since Net::HTTP provides a default that can break services.
  # We're setting one here even though it's not used or necessary.
  context.http_request.headers['content-type'] = 'application/x-amz-json-1.1'
  @handler.call(context)
end