> the second argument to serialise is used to say that you always want > the serialised object to be of a certain class (e.g. Hash, an > application specific class etc.). I'm not sure what you meant by > passing JSON as that argument but I suspect that it isn't doing what > you think it is. I was basing it on this article (as well as a stack overflow answer) that you can provide a custom serializer in Rails 3.1:
http://edgerails.info/articles/what-s-new-in-edge-rails/2011/03/09/custom-activerecord-attribute-serialization/index.html JSON provides a dump and load method on the class so it should be acceptable as the serializer. Is this article incorrect or my understanding of it? Cheers, Andy -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.