New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Eager load on nested items only populates first nested item in the collection #123
Comments
This is a limitation sadly...it will only populate one level. |
@subsociety can you give us output log thrown for this issue? |
@robbyoconnor he is actually loading it correctly. Look at the pasted output. Specifically the cancellation_rules at the beginning versus the end. @subsociety like @larrymjordan said please add any log output as well. |
@larrymjordan: Which output would you like to see? |
@subsociety I would like to see if any error was raised while loading inner level. However, I could replicate it and you're correct about this. It seems this happens when loading nested associations with the has_many type. I'm working on that fix. |
Thanks @larrymjordan, I can verify that there are no errors output in the logs. |
@mclark4386 ah so he is! I guess I didn't read it close enough -- sorry @subsociety ! |
Fixed with #124. |
Awesome fix, thanks guys! |
I have the following model structure:
When specifying eager loading on BenefitCategory for the nested Benefits.CancellationRule, I'm only seeing the nested values populated for the first BenefitCategory.
Execution of the call above results in the data:
The nested cancellation_rule values are only populated for the first item in the top level collection of benefit_categories. Debug statements in the pop.eagerAssocations() method hint that subsequent items in the collection are not processed.
The text was updated successfully, but these errors were encountered: