aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_view/helpers/capture_helper.rb
diff options
context:
space:
mode:
authorJon Leighton <j@jonathanleighton.com>2010-11-08 11:02:26 +0000
committerJon Leighton <j@jonathanleighton.com>2010-11-08 11:02:26 +0000
commite05162cffad7ae86615c21c6b54ab161d0261c39 (patch)
treec02e6faf12c2ce50ef4ac40342daf488d7fa0f8d /actionpack/lib/action_view/helpers/capture_helper.rb
parent083d6f267611472b8acfb9801e64971ee6d19994 (diff)
parent4e0477c9b75683372f662a614ae91b158120ebe8 (diff)
downloadrails-e05162cffad7ae86615c21c6b54ab161d0261c39.tar.gz
rails-e05162cffad7ae86615c21c6b54ab161d0261c39.tar.bz2
rails-e05162cffad7ae86615c21c6b54ab161d0261c39.zip
Merge branch 'master' into nested_has_many_through
Conflicts: activerecord/lib/active_record/associations.rb
Diffstat (limited to 'actionpack/lib/action_view/helpers/capture_helper.rb')
-rw-r--r--actionpack/lib/action_view/helpers/capture_helper.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/helpers/capture_helper.rb b/actionpack/lib/action_view/helpers/capture_helper.rb
index 0401e6a09b..c88bd1efd5 100644
--- a/actionpack/lib/action_view/helpers/capture_helper.rb
+++ b/actionpack/lib/action_view/helpers/capture_helper.rb
@@ -1,4 +1,5 @@
require 'active_support/core_ext/object/blank'
+require 'active_support/core_ext/string/output_safety'
module ActionView
# = Action View Capture Helper
@@ -38,7 +39,7 @@ module ActionView
value = nil
buffer = with_output_buffer { value = yield(*args) }
if string = buffer.presence || value and string.is_a?(String)
- string
+ ERB::Util.html_escape string
end
end