diff options
author | José Valim <jose.valim@gmail.com> | 2011-09-08 20:49:08 +0200 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2011-09-08 20:54:30 +0200 |
commit | 6b010c2690de9ffce4878a9471c8adb33d4a21a1 (patch) | |
tree | b6f6053d93b64672334701a6ff3d5aae5d41dfa8 /activesupport/lib/active_support/core_ext/string/output_safety.rb | |
parent | 0d254915819a9e5711895e410e1597177216c903 (diff) | |
download | rails-6b010c2690de9ffce4878a9471c8adb33d4a21a1.tar.gz rails-6b010c2690de9ffce4878a9471c8adb33d4a21a1.tar.bz2 rails-6b010c2690de9ffce4878a9471c8adb33d4a21a1.zip |
Revert removing gsub and sub from safe buffer.
Diffstat (limited to 'activesupport/lib/active_support/core_ext/string/output_safety.rb')
-rw-r--r-- | activesupport/lib/active_support/core_ext/string/output_safety.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/activesupport/lib/active_support/core_ext/string/output_safety.rb b/activesupport/lib/active_support/core_ext/string/output_safety.rb index f364a42354..4c9609c27a 100644 --- a/activesupport/lib/active_support/core_ext/string/output_safety.rb +++ b/activesupport/lib/active_support/core_ext/string/output_safety.rb @@ -75,8 +75,8 @@ end module ActiveSupport #:nodoc: class SafeBuffer < String - UNSAFE_STRING_METHODS = ["capitalize", "chomp", "chop", "delete", "downcase", "lstrip", "next", "reverse", "rstrip", "slice", "squeeze", "strip", "succ", "swapcase", "tr", "tr_s", "upcase"].freeze - UNAVAILABLE_STRING_METHODS = ["gsub", "sub"] + UNSAFE_STRING_METHODS = ["capitalize", "chomp", "chop", "delete", "downcase", "gsub", "lstrip", "next", "reverse", "rstrip", "slice", "squeeze", "strip", "sub", "succ", "swapcase", "tr", "tr_s", "upcase"].freeze + UNAVAILABLE_STRING_METHODS = [] alias_method :original_concat, :concat private :original_concat @@ -185,4 +185,4 @@ class String def html_safe ActiveSupport::SafeBuffer.new(self) end -end +end
\ No newline at end of file |