Skip to content

Commit

Permalink
Remove referencing indexes when reconfiguring a property as a navigation
Browse files Browse the repository at this point in the history
Fixes #29997
  • Loading branch information
AndriySvyryd committed Sep 10, 2024
1 parent 36e4637 commit cd99bbf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/EFCore/Metadata/Internal/InternalTypeBaseBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,7 @@ public virtual void RemoveMembersInHierarchy(string propertyName, ConfigurationS
{
if (conflictingProperty.GetConfigurationSource() != ConfigurationSource.Explicit)
{
conflictingProperty.DeclaringType.RemoveProperty(conflictingProperty);
conflictingProperty.DeclaringType.Builder.RemoveProperty(conflictingProperty, configurationSource);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1189,6 +1189,7 @@ protected class OneToManyOwnedWithField
public OneToManyOwnerWithField? OneToManyOwner { get; set; }
}

[Index(nameof(OwnedDependent))]
protected class OneToOneOwnerWithField
{
public int Id;
Expand Down

0 comments on commit cd99bbf

Please sign in to comment.