diff --git a/Zavala/DocumentsActivityItemsConfiguration.swift b/Zavala/DocumentsActivityItemsConfiguration.swift index 36833a48..92b0bd5f 100644 --- a/Zavala/DocumentsActivityItemsConfiguration.swift +++ b/Zavala/DocumentsActivityItemsConfiguration.swift @@ -53,11 +53,10 @@ extension DocumentsActivityItemsConfiguration: UIActivityItemsConfigurationReadi let itemProviders: [NSItemProvider] = selectedDocuments.compactMap { document in let itemProvider = NSItemProvider() + let data = document.formattedPlainText.data(using: .utf8) + itemProvider.registerDataRepresentation(forTypeIdentifier: UTType.utf8PlainText.identifier, visibility: .all) { completion in - Task { @MainActor in - let data = document.formattedPlainText.data(using: .utf8) - completion(data, nil) - } + completion(data, nil) return nil }