From d04c4fac3bb6f75ba15704dd03faeb5f2d7033f7 Mon Sep 17 00:00:00 2001 From: Andrey Ognevsky Date: Wed, 13 Nov 2013 00:18:36 +0400 Subject: Take Hash with options inside Array in #url_for --- actionpack/lib/action_dispatch/routing/url_for.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'actionpack/lib/action_dispatch') diff --git a/actionpack/lib/action_dispatch/routing/url_for.rb b/actionpack/lib/action_dispatch/routing/url_for.rb index bcebe532bf..4a0ef40873 100644 --- a/actionpack/lib/action_dispatch/routing/url_for.rb +++ b/actionpack/lib/action_dispatch/routing/url_for.rb @@ -155,6 +155,8 @@ module ActionDispatch _routes.url_for(options.symbolize_keys.reverse_merge!(url_options)) when String options + when Array + polymorphic_url(options, options.extract_options!) else polymorphic_url(options) end -- cgit v1.2.3