From 7e61670105fdb1efd164b2d89194a1699a9943db Mon Sep 17 00:00:00 2001 From: JP Dillingham Date: Mon, 4 May 2026 22:13:53 -0500 Subject: make create async --- src/slskd/Transfers/Downloads/BatchService.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/slskd/Transfers/Downloads/BatchService.cs b/src/slskd/Transfers/Downloads/BatchService.cs index 7a4ba055..29de8e14 100644 --- a/src/slskd/Transfers/Downloads/BatchService.cs +++ b/src/slskd/Transfers/Downloads/BatchService.cs @@ -49,7 +49,7 @@ public interface IBatchService /// /// The batch to create. /// The created batch. - Batch Create(Batch batch); + Task CreateAsync(Batch batch); /// /// Finds a single batch matching the specified . @@ -82,7 +82,7 @@ public class BatchService : IBatchService /// /// The batch to create. /// The created batch. - public Batch Create(Batch batch) + public async Task CreateAsync(Batch batch) { if (batch == default) { @@ -91,7 +91,7 @@ public class BatchService : IBatchService using var context = ContextFactory.CreateDbContext(); context.Batches.Add(batch); - context.SaveChanges(); + await context.SaveChangesAsync(); Log.Debug("Created batch {Id}", batch.Id); -- cgit v1.2.3