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

[BUGFIX] keep local state after a deletion #5058

Merged
merged 16 commits into from
Jul 14, 2017
4 changes: 2 additions & 2 deletions addon/-private/system/model/internal-model.js
Original file line number Diff line number Diff line change
Expand Up @@ -885,14 +885,14 @@ export default class InternalModel {
let rel = this._relationships.get(name);

rel.clear();
// rel.removeInverseRelationships();
rel.removeInverseRelationships();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hjdivad commenting these out didn't make any tests fail o.O

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm yeah it looks like the unload tests assert against the id map and the relationship payloads, but not against relationships (either our side or inverse).

}
});
Object.keys(this._implicitRelationships).forEach((key) => {
let rel = this._implicitRelationships[key];

rel.clear();
// rel.removeInverseRelationships();
rel.removeInverseRelationships();
});
}

Expand Down