Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,11 @@ private static void Apply(this Core2Group group, PatchOperation2 operation)
IList<Member> buffer = new List<Member>();
foreach (Member member in membersToAdd)
{
if(group.Members == null)
{
group.Members = Enumerable.Empty<Member>();
}

//O(n) with the number of group members, so for large groups this is not optimal
if (!group.Members.Any((Member item) =>
string.Equals(item.Value, member.Value, StringComparison.OrdinalIgnoreCase)))
Expand Down