-
Type: Task
-
Resolution: Done
-
Affects Version/s: None
-
Component/s: None
-
None
Hi,
I end up posting an issue since ActiveRecord does the STI conversion by default.
Considering the following code:
class User include Mongoid::Document embeds_many :base_foos end class BaseFoo include Mongoid::Document embedded_in :user end class Bar < BaseFoo end class Baz < BaseFoo end
`
When I do:
user.base_foos
Could I somehow have the objects casted in their proper type (without breaking lazy load)?
ie , I'd like to get Bar}}s and {{Baz}}s, no {{BaseFoos.
I'm using Mongoid 2.4.9 and also checked with 2.6.0.
Thanks,