activesupport/json/encoders fix that to_json should call rails_to_json, not just be an alias to the rails_to_json method defined in Object. Fixes #2690

Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
This commit is contained in:
Hongli Lai (Phusion)
2009-05-24 11:46:39 +02:00
committed by Pratik Naik
parent a70c78177a
commit 9b2a665aff

View File

@@ -4,5 +4,7 @@ class Object
ActiveSupport::JSON.encode(instance_values, options)
end
alias to_json rails_to_json
def to_json(*args)
rails_to_json(*args)
end
end