Skip to content
Merged
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 @@ -161,7 +161,7 @@ private static async Task<int> UpdateOAuthInDatabase(this INullinsideContext db,
/// <param name="stoppingToken">The stopping token.</param>
public static async Task SaveTwitchBans(this INullinsideContext db, string channelId,
IEnumerable<(string Id, string Username)> bannedUsers, string reason, CancellationToken stoppingToken = new()) {
List<string> banUserIds = bannedUsers.Select(b => b.Id).ToList();
List<string> banUserIds = bannedUsers.Select(b => b.Id).ToHashSet().ToList();
HashSet<string?> existingUsers = db.TwitchUser
.AsNoTracking()
.Where(u => null != u.TwitchId && banUserIds.Contains(u.TwitchId))
Expand Down