Fix render(:update) to not render layouts

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3472 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
Sam Stephenson
2006-01-23 16:29:37 +00:00
parent 5f44411d94
commit 4d49f2ca09
3 changed files with 5 additions and 1 deletions

View File

@@ -1,5 +1,7 @@
*SVN*
* Fix render(:update) to not render layouts. [Sam Stephenson]
* Fixed that SSL would not correctly be detected when running lighttpd/fcgi behind lighttpd w/mod_proxy #3548 [stephen_purcell@yahoo.com]
* Added the possibility to specify atomatic expiration for the memcachd session container #3571 [Stefan Kaes]

View File

@@ -236,6 +236,7 @@ module ActionController #:nodoc:
private
def apply_layout?(template_with_options, options)
return false if options == :update
template_with_options ? candidate_for_layout?(options) : !template_exempt_from_layout?
end

View File

@@ -223,7 +223,7 @@ class NewRenderTestController < ActionController::Base
"render_with_explicit_template",
"render_js_with_explicit_template",
"render_js_with_explicit_action_template",
"delete_with_js"
"delete_with_js", "update_page"
"layouts/standard"
when "builder_layout_test"
@@ -489,6 +489,7 @@ class NewRenderTest < Test::Unit::TestCase
def test_update_page
get :update_page
assert_template nil
assert_equal 'text/javascript', @response.headers['Content-type']
assert_equal 2, @response.body.split($/).length
end