aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/CHANGELOG2
-rwxr-xr-xactionpack/lib/action_controller/base.rb2
2 files changed, 3 insertions, 1 deletions
diff --git a/actionpack/CHANGELOG b/actionpack/CHANGELOG
index e1c1ef5391..ba7b22b7f7 100644
--- a/actionpack/CHANGELOG
+++ b/actionpack/CHANGELOG
@@ -1,5 +1,7 @@
*SVN*
+* Fixed render_partial_collection to output an empty string instead of nil when handed an empty array #1202 [Ryan Carver]
+
* Improved the speed of regular expression expirations for caching by a factor of 10 #1221 [Jamis Buck]
* Removed dumping of template assigns on the rescue page as it would very easily include a ton of data making page loads take seconds (and the information was rarely helpful) #1222
diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb
index 15724e2e36..eebca26191 100755
--- a/actionpack/lib/action_controller/base.rb
+++ b/actionpack/lib/action_controller/base.rb
@@ -504,7 +504,7 @@ module ActionController #:nodoc:
# Renders a collection of partials using <tt>partial_name</tt> to iterate over the +collection+.
def render_partial_collection(partial_name, collection, partial_spacer_template = nil, local_assigns = {})#:doc:
add_variables_to_assigns
- render_text(@template.render_collection_of_partials(partial_name, collection, partial_spacer_template, local_assigns))
+ render_text(@template.render_collection_of_partials(partial_name, collection, partial_spacer_template, local_assigns) || '')
end
# Sends the file by streaming it 4096 bytes at a time. This way the