diff options
author | José Valim <jose.valim@gmail.com> | 2010-01-29 16:49:26 +0100 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-01-29 17:51:05 +0100 |
commit | 986a4e616be715e5c5a6ebbd25d339fa9bba4072 (patch) | |
tree | 29f2051bc1f51785662035a1d4740d287ff817a0 /actionpack/lib/abstract_controller | |
parent | ba82eb2efa24c9124fc4b3dac65c7b7494022f99 (diff) | |
download | rails-986a4e616be715e5c5a6ebbd25d339fa9bba4072.tar.gz rails-986a4e616be715e5c5a6ebbd25d339fa9bba4072.tar.bz2 rails-986a4e616be715e5c5a6ebbd25d339fa9bba4072.zip |
Fix rendering of layouts.
Diffstat (limited to 'actionpack/lib/abstract_controller')
-rw-r--r-- | actionpack/lib/abstract_controller/rendering.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/actionpack/lib/abstract_controller/rendering.rb b/actionpack/lib/abstract_controller/rendering.rb index 1dec3f2c3e..40cac40ba7 100644 --- a/actionpack/lib/abstract_controller/rendering.rb +++ b/actionpack/lib/abstract_controller/rendering.rb @@ -157,7 +157,8 @@ module AbstractController options[:_template_name] = options[:file] end - name = (options[:_template_name] || action_name).to_s + name = (options[:_template_name] || options[:action] || action_name).to_s + options[:_prefix] ||= _prefix if (options.keys & [:partial, :file, :template]).empty? options[:_template] ||= with_template_cache(name) do find_template(name, { :formats => formats }, options) |