Skip to content

Commit

Permalink
Allow member actions (get, etc) to accept strings, with test
Browse files Browse the repository at this point in the history
  • Loading branch information
indirect authored and josevalim committed Aug 17, 2010
1 parent a0ca3d1 commit fca617a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions actionpack/lib/action_dispatch/routing/mapper.rb
Expand Up @@ -731,6 +731,7 @@ def match(*args)
end
elsif resource_method_scope?
path = path_for_custom_action
options[:action] ||= action
options[:as] = name_for_action(options[:as]) if options[:as]
args.push(options)

Expand Down
2 changes: 1 addition & 1 deletion actionpack/test/dispatch/routing_test.rb
Expand Up @@ -128,7 +128,7 @@ def self.matches?(request)
end

member do
get :some_path_with_name
get 'some_path_with_name'
put :accessible_projects
post :resend, :generate_new_password
end
Expand Down

0 comments on commit fca617a

Please sign in to comment.