From 7846fb79e1296986c41250bfea2e115e7683fa61 Mon Sep 17 00:00:00 2001 From: Carlos Antonio da Silva Date: Thu, 11 Nov 2010 11:08:17 -0200 Subject: Fix render partial with layout and no block When using a render :partial with :layout call, without giving a block, if the given :partial had another render :partial call, the layout was not being rendered. This commit fixes this context by storing variables before rendering the partial, so they are not overrided in any successive call to render partials down the path. All ActionPack tests are ok. --- actionpack/test/fixtures/test/_partial_with_partial.erb | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 actionpack/test/fixtures/test/_partial_with_partial.erb (limited to 'actionpack/test/fixtures') diff --git a/actionpack/test/fixtures/test/_partial_with_partial.erb b/actionpack/test/fixtures/test/_partial_with_partial.erb new file mode 100644 index 0000000000..ee0d5037b6 --- /dev/null +++ b/actionpack/test/fixtures/test/_partial_with_partial.erb @@ -0,0 +1,2 @@ +<%= render 'test/partial' %> +partial with partial -- cgit v1.2.3