This project is archived and is in readonly mode.

Changeset [33b954005cd71f1bfba1beca296804ce6c66b0a8] by Jeremy Kemper

September 7th, 2010 @ 07:33 PM

fixed some issues with JSON encoding

  • as_json in ActiveModel should return a hash and handle :only/:except/:methods options
  • Array and Hash should call as_json on their elements
  • json methods should not modify options argument

[#5374 state:committed]

Signed-off-by: Jeremy Kemper jeremy@bitsweat.net

Conflicts:

activemodel/lib/active_model/serialization.rb

http://github.com/rails/rails/commit/33b954005cd71f1bfba1beca296804...

Committed by Jeremy Kemper

  • M activemodel/lib/active_model/serialization.rb
  • M activemodel/lib/active_model/serializers/json.rb
  • M activemodel/test/cases/serializeration/json_serialization_test.rb
  • M activerecord/lib/active_record/relation.rb
  • M activerecord/lib/active_record/serialization.rb
  • M activerecord/test/cases/json_serialization_test.rb
  • M activesupport/lib/active_support/json/encoding.rb
  • M activesupport/test/json/encoding_test.rb

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>