-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Fix for issue #1954 - not throwing on duplicate property #2077
Conversation
@@ -77,7 +71,13 @@ private EntityType(object typeOrName, Model model) | |||
|
|||
Model = model; | |||
|
|||
_foreignKeys = new SortedDictionary<IReadOnlyList<Property>, ForeignKey>(PropertyListComparer.Instance); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did anything change here? Why have these been moved?
Can you describe the change a little more? In particular, the "reference based propagation" approach. |
8fb4064
to
386a9a2
Compare
Updated based on feedback |
386a9a2
to
22a4b39
Compare
@@ -37,9 +37,11 @@ public class EntityType : Annotatable, IEntityType | |||
private Key _primaryKey; | |||
private EntityType _baseType; | |||
|
|||
public event EventHandler<Property> PropertyMetadataChanged; | |||
private IEnumerable<EntityType> DerivedTypes => Model.EntityTypes.Where(t => t.BaseType == this); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make this a method and rename to something like GetDirectDescendents
22a4b39
to
49373ae
Compare
Not sure if there is anything outstanding here... if not. |
49373ae
to
50cfff5
Compare
Fix for #1954
Switching from event based to reference based propagation of property metadata changes to allow for full traversals when adding a base type to an existing tree.
@ajcvickers @anpete