aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2013-09-11 17:40:02 -0700
committerJeremy Kemper <jeremy@bitsweat.net>2013-09-11 17:40:02 -0700
commitaf9caae9eb665e1a54e05a48a3fcda5b438a28a7 (patch)
treee79209a08ebce3d70021fe06b250a134c8cdcf95 /activesupport/lib
parent71cf717ee297bc2407de304e5a880f1e39ab4f3c (diff)
parentb9e142af529b20720fc34bc5f563e935a7ef7cda (diff)
downloadrails-af9caae9eb665e1a54e05a48a3fcda5b438a28a7.tar.gz
rails-af9caae9eb665e1a54e05a48a3fcda5b438a28a7.tar.bz2
rails-af9caae9eb665e1a54e05a48a3fcda5b438a28a7.zip
Merge pull request #12201 from chancancode/json_load
Replace JSON.load with JSON.parse
Diffstat (limited to 'activesupport/lib')
-rw-r--r--activesupport/lib/active_support/json/decoding.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activesupport/lib/active_support/json/decoding.rb b/activesupport/lib/active_support/json/decoding.rb
index 30833a4cb1..2533ff43e1 100644
--- a/activesupport/lib/active_support/json/decoding.rb
+++ b/activesupport/lib/active_support/json/decoding.rb
@@ -13,8 +13,8 @@ module ActiveSupport
#
# ActiveSupport::JSON.decode("{\"team\":\"rails\",\"players\":\"36\"}")
# => {"team" => "rails", "players" => "36"}
- def decode(json, proc = nil, options = {})
- data = ::JSON.load(json, proc, options)
+ def decode(json, options = {})
+ data = ::JSON.parse(json, options.merge(create_additions: false))
if ActiveSupport.parse_json_times
convert_dates_from(data)
else