aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_controller/abstract
diff options
context:
space:
mode:
authorYehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com>2009-05-01 16:02:37 -0700
committerYehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com>2009-05-01 17:31:02 -0700
commit918b119bd3310c15dab4eb8a3317cc2a32503119 (patch)
tree59d12074b0ee955c80843109ef1551f13279e8d1 /actionpack/lib/action_controller/abstract
parentb4903a8e34da77b96ea136ccd015c1634a8a5c2b (diff)
downloadrails-918b119bd3310c15dab4eb8a3317cc2a32503119.tar.gz
rails-918b119bd3310c15dab4eb8a3317cc2a32503119.tar.bz2
rails-918b119bd3310c15dab4eb8a3317cc2a32503119.zip
Add support for stripping "layouts/" from the layout name
Diffstat (limited to 'actionpack/lib/action_controller/abstract')
-rw-r--r--actionpack/lib/action_controller/abstract/layouts.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/actionpack/lib/action_controller/abstract/layouts.rb b/actionpack/lib/action_controller/abstract/layouts.rb
index f56b9dd914..eb3b73289d 100644
--- a/actionpack/lib/action_controller/abstract/layouts.rb
+++ b/actionpack/lib/action_controller/abstract/layouts.rb
@@ -57,6 +57,9 @@ module AbstractController
def _layout() end # This will be overwritten
+ # :api: plugin
+ # ====
+ # Override this to mutate the inbound layout name
def _layout_for_name(name)
unless [String, FalseClass, NilClass].include?(name.class)
raise ArgumentError, "String, false, or nil expected; you passed #{name.inspect}"