Fix serialization of objects within ArrayList