aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support/json/encoding.rb
diff options
context:
space:
mode:
authorwycats <wycats@gmail.com>2010-04-30 11:17:58 -0700
committerwycats <wycats@gmail.com>2010-04-30 11:17:58 -0700
commit0fe8827bf384cb99ab757236555c7af18793d515 (patch)
treea7ac2143c78964cad8ee87d9ff8a1c52abf61249 /activesupport/lib/active_support/json/encoding.rb
parent91963e9e33eb5a28297323f1346aeb8b643e9d65 (diff)
parent6b559474fb7fae0160860fc62752da347af032b2 (diff)
downloadrails-0fe8827bf384cb99ab757236555c7af18793d515.tar.gz
rails-0fe8827bf384cb99ab757236555c7af18793d515.tar.bz2
rails-0fe8827bf384cb99ab757236555c7af18793d515.zip
Merge branch 'master' of github.com:rails/rails
Diffstat (limited to 'activesupport/lib/active_support/json/encoding.rb')
-rw-r--r--activesupport/lib/active_support/json/encoding.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/json/encoding.rb b/activesupport/lib/active_support/json/encoding.rb
index 0f38fd0e89..e692f6d142 100644
--- a/activesupport/lib/active_support/json/encoding.rb
+++ b/activesupport/lib/active_support/json/encoding.rb
@@ -104,7 +104,7 @@ module ActiveSupport
def escape(string)
if string.respond_to?(:force_encoding)
- string = string.encode(::Encoding::UTF_8, undef: :replace).force_encoding(::Encoding::BINARY)
+ string = string.encode(::Encoding::UTF_8, :undef => :replace).force_encoding(::Encoding::BINARY)
end
json = string.
gsub(escape_regex) { |s| ESCAPED_CHARS[s] }.