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

Delete optional orphans when foreign key value is set to null #25957

Merged
merged 1 commit into from
Sep 10, 2021

Conversation

ajcvickers
Copy link
Member

Fixes #25360

This is a case where an optional relationship is configured with delete orphans behavior. Since the relationship is optional it means that the FK value can be explicitly set to null. (This is not possible for required relationships, which is the usual case for delete orphans.) In this case the navigation fixer was not triggering behavior in the state manager to process deleting orphans.

Fixes #25360

This is a case where an optional relationship is configured with delete orphans behavior. Since the relationship is optional it means that the FK value can be explicitly set to null. (This is not possible for required relationships, which is the usual case for delete orphans.) In this case the navigation fixer was not triggering behavior in the state manager to process deleting orphans.
@ajcvickers ajcvickers requested a review from a team September 9, 2021 11:52
@ajcvickers ajcvickers merged commit 50daaa1 into release/6.0 Sep 10, 2021
@ajcvickers ajcvickers deleted the FoodWaste0909 branch September 10, 2021 05:11
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.

Setting foreign key to null by PropertyEntry.CurrentValue deletes entity
2 participants