Skip to content
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

Clarify load/reload behavior #5735

Merged
merged 1 commit into from
Nov 3, 2018
Merged

Clarify load/reload behavior #5735

merged 1 commit into from
Nov 3, 2018

Conversation

ahawkins
Copy link
Contributor

@ahawkins ahawkins commented Nov 2, 2018

I was bit hard by this. I expected that calling either of these methods would re-query the relationship through the adapter. This isn't the case. I further understood what was going on reading the source while implementing my own adapters. This commit hopefully clarifies the behavior. If the relationship has a "link", then findHasMany is called to re-query the relationship. Otherwise, all existing records are reload.

I was bit hard by this. I expected that calling either of these methods would re-query the relationship through the adapter. This isn't the case. I further understood what was going on reading the source while implementing my own adapters. This commit hopefully clarifies the behavior. If the relationship has a "link", then `findHasMany` is called to re-query the relationship. Otherwise, all existing records are reload.
@ahawkins ahawkins changed the title [DOCS has-many]: clarify load/reload behavior Clarify load/reload behavior Nov 2, 2018
@runspired runspired merged commit 41bac4e into emberjs:master Nov 3, 2018
@ahawkins ahawkins deleted the patch-1 branch November 5, 2018 04:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants