Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

router: transform extract keys from symbol to strings #134

wants to merge 1 commit into
Jump to file or symbol
Failed to load files and symbols.
+5 −1
@@ -35,7 +35,11 @@ def self.build(klass, api)
route.to do |env|
builder = Builder.new
env['params'] ||= {}
- env['params'].merge!(env['router.params']) if env['router.params']
+ if env['router.params']
+ # transform the keys into string
+ env['params'].merge!( Hash[env['router.params'].map{|k,v| [k.to_s, v] }] )
+ end
builder.params = builder.retrieve_params(env)
builder.instance_eval(&blk) if blk