class Aws::S3::Plugins::LocationConstraint::Handler

Public Instance Methods

call(context) click to toggle source
# File lib/aws-sdk-s3/plugins/location_constraint.rb, line 14
def call(context)
  unless context.config.region == 'us-east-1'
    populate_location_constraint(context.params, context.config.region)
  end
  @handler.call(context)
end

Private Instance Methods

populate_location_constraint(params, region) click to toggle source
# File lib/aws-sdk-s3/plugins/location_constraint.rb, line 23
def populate_location_constraint(params, region)
  params[:create_bucket_configuration] ||= {}
  params[:create_bucket_configuration][:location_constraint] ||= region
end