From d1529a71d120a8533f7e042b8e92698428c7a3a1 Mon Sep 17 00:00:00 2001 From: Nicholas Seckar Date: Wed, 22 Nov 2006 16:31:00 +0000 Subject: Update Routing to complain when :controller is not specified by a route. Closes #6669. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5607 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionpack/lib/action_controller/routing.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'actionpack/lib') diff --git a/actionpack/lib/action_controller/routing.rb b/actionpack/lib/action_controller/routing.rb index 3c53acc164..2fe74c5b34 100644 --- a/actionpack/lib/action_controller/routing.rb +++ b/actionpack/lib/action_controller/routing.rb @@ -950,6 +950,10 @@ module ActionController route.significant_keys << :action end + if !route.significant_keys.include?(:controller) + raise ArgumentError, "Illegal route: the :controller must be specified!" + end + route end end -- cgit v1.2.3