diff options
author | Andrew White <andyw@pixeltrix.co.uk> | 2014-01-05 08:43:12 +0000 |
---|---|---|
committer | Andrew White <andyw@pixeltrix.co.uk> | 2014-01-05 08:43:12 +0000 |
commit | b9efc74f9e63e76f121204a96073d2f5582f66e6 (patch) | |
tree | 8bcbb5e6af1eb03cf1664faf699f9e60223ea905 /actionpack/lib/action_dispatch/routing/route_set.rb | |
parent | d017e92e1d825c6bf9fa49c339c55ca920effe45 (diff) | |
download | rails-b9efc74f9e63e76f121204a96073d2f5582f66e6.tar.gz rails-b9efc74f9e63e76f121204a96073d2f5582f66e6.tar.bz2 rails-b9efc74f9e63e76f121204a96073d2f5582f66e6.zip |
Simplify arg parameterization
Diffstat (limited to 'actionpack/lib/action_dispatch/routing/route_set.rb')
-rw-r--r-- | actionpack/lib/action_dispatch/routing/route_set.rb | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb index bbdcc7c5d3..1ea3bb17ce 100644 --- a/actionpack/lib/action_dispatch/routing/route_set.rb +++ b/actionpack/lib/action_dispatch/routing/route_set.rb @@ -202,12 +202,7 @@ module ActionDispatch end def parameterize_args(args) - [].tap do |parameterized_args| - @required_parts.zip(args) do |part, arg| - parameterized_arg = arg.to_param - parameterized_args << [part, parameterized_arg] - end - end + @required_parts.zip(args.map(&:to_param)) end def missing_keys(args) |