Sha256: 4f1d8d25892d4bdce1450ffccdf46d617375955ac633250a98aa364e7b8062ab
Contents?: true
Size: 749 Bytes
Versions: 12
Compression:
Stored size: 749 Bytes
Contents
# frozen_string_literal: true module Aws module SSO module Plugins class ContentType < Seahorse::Client::Plugin def add_handlers(handlers, config) handlers.add(Handler) end class Handler < Seahorse::Client::Handler def call(context) # Some SSO 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/json' @handler.call(context) end end end end end end
Version data entries
12 entries across 12 versions & 2 rubygems