From dd58f4021da30af7f40ee139e7487b887cac44e9 Mon Sep 17 00:00:00 2001 From: Yehuda Katz + Carl Lerche Date: Tue, 16 Jun 2009 13:44:51 -0700 Subject: An exception is raised if a layout is missing only if the layout is missing for all mimes --- actionpack/lib/action_controller/base/layouts.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'actionpack/lib/action_controller/base/layouts.rb') diff --git a/actionpack/lib/action_controller/base/layouts.rb b/actionpack/lib/action_controller/base/layouts.rb index ace4b148c9..5c55e9745e 100644 --- a/actionpack/lib/action_controller/base/layouts.rb +++ b/actionpack/lib/action_controller/base/layouts.rb @@ -176,7 +176,7 @@ module ActionController super return if (options.key?(:text) || options.key?(:inline) || options.key?(:partial)) && !options.key?(:layout) - layout = options.key?(:layout) ? options[:layout] : :none + layout = options.key?(:layout) ? options[:layout] : :default options[:_layout] = _layout_for_option(layout, options[:_template].details) end @@ -184,7 +184,7 @@ module ActionController case name when String then _layout_for_name(name, details) when true then _default_layout(details, true) - when :none then _default_layout(details, false) + when :default then _default_layout(details, false) when false, nil then nil else raise ArgumentError, -- cgit v1.2.3