Fix concurrency warning.

This commit is contained in:
Brent Simmons 2024-04-19 22:20:36 -07:00
parent ee466170c8
commit dac3ff01b3

View File

@ -917,7 +917,7 @@ public protocol CloudKitZone: AnyObject {
var recordToSaveChunks = recordsToSave.chunked(into: 200)
var recordIDsToDeleteChunks = recordIDsToDelete.chunked(into: 200)
func saveChunks(completion: @escaping (Result<Void, Error>) -> Void) {
@MainActor func saveChunks(completion: @escaping (Result<Void, Error>) -> Void) {
if !recordToSaveChunks.isEmpty {
let records = recordToSaveChunks.removeFirst()