Loading commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Activity.kt +5 −1 Original line number Diff line number Diff line Loading @@ -562,7 +562,11 @@ fun BaseSimpleActivity.getFileOutputStream(fileDirItem: FileDirItem, callback: ( } } } else { try { callback(FileOutputStream(File(fileDirItem.path))) } catch (e: Exception) { callback(null) } } } Loading commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Context-storage.kt +5 −1 Original line number Diff line number Diff line Loading @@ -135,7 +135,11 @@ fun Context.getMyFileUri(file: File): Uri { fun Context.tryFastDocumentDelete(path: String, allowDeleteFolder: Boolean): Boolean { val document = getFastDocumentFile(path) return if (document?.isFile == true || allowDeleteFolder) { try { DocumentsContract.deleteDocument(contentResolver, document?.uri) } catch (e: Exception) { false } } else { false } Loading Loading
commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Activity.kt +5 −1 Original line number Diff line number Diff line Loading @@ -562,7 +562,11 @@ fun BaseSimpleActivity.getFileOutputStream(fileDirItem: FileDirItem, callback: ( } } } else { try { callback(FileOutputStream(File(fileDirItem.path))) } catch (e: Exception) { callback(null) } } } Loading
commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Context-storage.kt +5 −1 Original line number Diff line number Diff line Loading @@ -135,7 +135,11 @@ fun Context.getMyFileUri(file: File): Uri { fun Context.tryFastDocumentDelete(path: String, allowDeleteFolder: Boolean): Boolean { val document = getFastDocumentFile(path) return if (document?.isFile == true || allowDeleteFolder) { try { DocumentsContract.deleteDocument(contentResolver, document?.uri) } catch (e: Exception) { false } } else { false } Loading