Skip to content

Commit

Permalink
Make the annotations SortedDictionary use ordinal ordering (#25490)
Browse files Browse the repository at this point in the history
Closes #25489
  • Loading branch information
roji authored Aug 11, 2021
1 parent dd41bd7 commit 68cfaf9
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/EFCore/Infrastructure/AnnotatableBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -149,11 +149,7 @@ public virtual void SetAnnotation(string name, object? value)
{
EnsureMutable();

if (_annotations == null)
{
_annotations = new SortedDictionary<string, Annotation>();
}

_annotations ??= new SortedDictionary<string, Annotation>(StringComparer.Ordinal);
_annotations[name] = annotation;

return OnAnnotationSet(name, annotation, oldAnnotation);
Expand Down

0 comments on commit 68cfaf9

Please sign in to comment.