diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2004-11-25 23:51:46 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2004-11-25 23:51:46 +0000 |
commit | d8207adb5f59693e7c00fb17dc9a28fd10a8c1a0 (patch) | |
tree | 404e523e6396fb586ad5557caf47ae91b5c02665 /actionpack | |
parent | 7ed0894c37a0222eaaa256cc9be19647c108e432 (diff) | |
download | rails-d8207adb5f59693e7c00fb17dc9a28fd10a8c1a0.tar.gz rails-d8207adb5f59693e7c00fb17dc9a28fd10a8c1a0.tar.bz2 rails-d8207adb5f59693e7c00fb17dc9a28fd10a8c1a0.zip |
Added the opportunity to defined method_missing on a controller which will handle all requests for actions not otherwise defined #223 [timb]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@15 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/CHANGELOG | 4 | ||||
-rwxr-xr-x | actionpack/lib/action_controller/base.rb | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/actionpack/CHANGELOG b/actionpack/CHANGELOG index 6b2c6e41e3..77cb4ee6f1 100644 --- a/actionpack/CHANGELOG +++ b/actionpack/CHANGELOG @@ -1,4 +1,6 @@ -*CVS* +*SVN* + +* Added the opportunity to defined method_missing on a controller which will handle all requests for actions not otherwise defined #223 [timb] * Fixed AbstractRequest#remote_ip for users going through proxies - Patch #228 [Eric Hodel] diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb index 0cbcbbf688..4816ef7f71 100755 --- a/actionpack/lib/action_controller/base.rb +++ b/actionpack/lib/action_controller/base.rb @@ -599,7 +599,7 @@ module ActionController #:nodoc: end def perform_action - if action_methods.include?(action_name) + if action_methods.include?(action_name) || action_methods.include?('method_missing') send(action_name) render unless @performed_render || @performed_redirect elsif template_exists? && template_public? |