diff --git a/DysonNetwork.Sphere/Account/AccountService.cs b/DysonNetwork.Sphere/Account/AccountService.cs index 76529c3..eddd66b 100644 --- a/DysonNetwork.Sphere/Account/AccountService.cs +++ b/DysonNetwork.Sphere/Account/AccountService.cs @@ -62,7 +62,7 @@ public class AccountService( if (missingId.Count != 0) { var newProfiles = missingId.Select(id => new Profile { AccountId = id }).ToList(); - await db.BulkInsertAsync(newProfiles); + await db.BulkInsertAsync(newProfiles, config => config.ConflictOption = ConflictOption.Ignore); } } } \ No newline at end of file diff --git a/DysonNetwork.Sphere/Storage/Handlers/ActionLogFlushHandler.cs b/DysonNetwork.Sphere/Storage/Handlers/ActionLogFlushHandler.cs index 8798ff7..f71e8a4 100644 --- a/DysonNetwork.Sphere/Storage/Handlers/ActionLogFlushHandler.cs +++ b/DysonNetwork.Sphere/Storage/Handlers/ActionLogFlushHandler.cs @@ -11,7 +11,7 @@ public class ActionLogFlushHandler(IServiceProvider serviceProvider) : IFlushHan using var scope = serviceProvider.CreateScope(); var db = scope.ServiceProvider.GetRequiredService(); - await db.BulkInsertAsync(items); + await db.BulkInsertAsync(items, config => config.ConflictOption = ConflictOption.Ignore); } }