diff --git a/Iceshrimp.Backend/Core/Federation/ActivityPub/ActivityDeliverService.cs b/Iceshrimp.Backend/Core/Federation/ActivityPub/ActivityDeliverService.cs index 31f71a13..d76dace4 100644 --- a/Iceshrimp.Backend/Core/Federation/ActivityPub/ActivityDeliverService.cs +++ b/Iceshrimp.Backend/Core/Federation/ActivityPub/ActivityDeliverService.cs @@ -31,7 +31,7 @@ public class ActivityDeliverService( // @formatter:on } - public async Task DeliverToAsync(ASActivity activity, User actor, params User[] recipients) + public async Task DeliverToAsync(ASActivity activity, User actor, params IEnumerable recipients) { logger.LogDebug("Queuing deliver-to-recipients jobs for activity {id}", activity.Id); if (activity.Actor == null) throw new Exception("Actor must not be null"); diff --git a/Iceshrimp.Backend/Core/Queues/BackgroundTaskQueue.cs b/Iceshrimp.Backend/Core/Queues/BackgroundTaskQueue.cs index 297795a2..1433658b 100644 --- a/Iceshrimp.Backend/Core/Queues/BackgroundTaskQueue.cs +++ b/Iceshrimp.Backend/Core/Queues/BackgroundTaskQueue.cs @@ -93,7 +93,7 @@ public class BackgroundTaskQueue(int parallelism) else { var storageSvc = scope.GetRequiredService(); - await storageSvc.RemoveFilesAsync(paths.Where(p => p != null).Select(p => p!).ToArray()); + await storageSvc.RemoveFilesAsync(paths.Where(p => p != null).Select(p => p!)); } } @@ -152,7 +152,7 @@ public class BackgroundTaskQueue(int parallelism) var rendered = await noteRenderer.RenderAsync(note); var activity = ActivityPub.ActivityRenderer.RenderUpdate(rendered, actor); - await deliverSvc.DeliverToAsync(activity, note.User, voters.ToArray()); + await deliverSvc.DeliverToAsync(activity, note.User, voters); } } diff --git a/Iceshrimp.Backend/Core/Services/NoteService.cs b/Iceshrimp.Backend/Core/Services/NoteService.cs index e521ee20..db00a9b2 100644 --- a/Iceshrimp.Backend/Core/Services/NoteService.cs +++ b/Iceshrimp.Backend/Core/Services/NoteService.cs @@ -710,7 +710,7 @@ public class NoteService( // @formatter:on if (note.Visibility == Note.NoteVisibility.Specified) - await deliverSvc.DeliverToAsync(activity, note.User, recipients.ToArray()); + await deliverSvc.DeliverToAsync(activity, note.User, recipients); else await deliverSvc.DeliverToFollowersAsync(activity, note.User, recipients); } diff --git a/Iceshrimp.Backend/Core/Services/ObjectStorageService.cs b/Iceshrimp.Backend/Core/Services/ObjectStorageService.cs index fb5e5399..88d83cd5 100644 --- a/Iceshrimp.Backend/Core/Services/ObjectStorageService.cs +++ b/Iceshrimp.Backend/Core/Services/ObjectStorageService.cs @@ -120,7 +120,7 @@ public class ObjectStorageService(IOptions config, HttpCl } } - public async Task RemoveFilesAsync(params string[] filenames) + public async Task RemoveFilesAsync(params IEnumerable filenames) { if (_bucket == null) throw new Exception("Refusing to remove file from object storage with invalid configuration");