Minor bug fixes, changes and model/activerecord serialization.