From 9dc3dec72ebad11c4a4d61b937bf933c04480058 Mon Sep 17 00:00:00 2001 From: Jorge Martin Espinosa Date: Thu, 18 Jun 2026 15:48:21 +0200 Subject: [PATCH] Replace `ContentResolver.delete` usage with a backwards-compatible version (#7053) The previous signature needed API 30, the new one is available since API 1 --- .../element/android/features/share/impl/DefaultOnSharedData.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/features/share/impl/src/main/kotlin/io/element/android/features/share/impl/DefaultOnSharedData.kt b/features/share/impl/src/main/kotlin/io/element/android/features/share/impl/DefaultOnSharedData.kt index b3ae822790..daab3787b3 100644 --- a/features/share/impl/src/main/kotlin/io/element/android/features/share/impl/DefaultOnSharedData.kt +++ b/features/share/impl/src/main/kotlin/io/element/android/features/share/impl/DefaultOnSharedData.kt @@ -35,7 +35,7 @@ class DefaultOnSharedData( for (sharedUri in data.uris) { // Remove the local copy of the shared file, as it is not needed anymore if (sharedUri.uri.scheme == ContentResolver.SCHEME_CONTENT && sharedUri.uri.host == fileProvider) { - context.contentResolver.delete(sharedUri.uri, null) + context.contentResolver.delete(sharedUri.uri, null, emptyArray()) } } revokeUriPermissions(data.uris.map { it.uri })