aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2010-04-27 02:36:34 -0700
committerXavier Noria <fxn@hashref.com>2010-04-27 02:36:34 -0700
commit1d63129eff1e25dd22e182cdef40ec61bf5dde88 (patch)
tree7afa3efc9c5e34f5db0a9fe98317bc08395bc4c4 /activesupport
parentc1d73270717f30498f8f4d55d6695509107c2834 (diff)
downloadrails-1d63129eff1e25dd22e182cdef40ec61bf5dde88.tar.gz
rails-1d63129eff1e25dd22e182cdef40ec61bf5dde88.tar.bz2
rails-1d63129eff1e25dd22e182cdef40ec61bf5dde88.zip
use ordinary syntax for options to be well-formed in 1.8
Diffstat (limited to 'activesupport')
-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] }.