Module: Grape::Extensions::Hash::ParamBuilder

Extended by:
ActiveSupport::Concern
Defined in:
lib/grape/extensions/hash.rb

Instance Method Summary collapse

Instance Method Details

#build_paramsObject



13
14
15
16
17
18
19
20
21
22
# File 'lib/grape/extensions/hash.rb', line 13

def build_params
  rack_params.deep_dup.tap do |params|
    params.deep_symbolize_keys!

    if env.key?(Grape::Env::GRAPE_ROUTING_ARGS)
      grape_routing_args.deep_symbolize_keys!
      params.deep_merge!(grape_routing_args)
    end
  end
end