Skip to content
Browse files

DRY AS::SafeBuffer a bit using existing helper

  • Loading branch information...
1 parent 6df507e commit 848289589edb74767cb97de9ed37a545a8d8b901 @rwz rwz committed Apr 2, 2014
Showing with 1 addition and 5 deletions.
  1. +1 −5 activesupport/lib/active_support/core_ext/string/output_safety.rb
View
6 activesupport/lib/active_support/core_ext/string/output_safety.rb
@@ -171,11 +171,7 @@ def clone_empty
%w[concat prepend].each do |method_name|
define_method method_name do |value|
- if !html_safe? || value.html_safe?
- super(value)
- else
- super(ERB::Util.h(value))
- end
+ super(html_escape_interpolated_argument(value))
end
end
alias << concat

0 comments on commit 8482895

Please sign in to comment.
Something went wrong with that request. Please try again.