diff --git a/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt b/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt index aa21d2cbf..333d1908b 100644 --- a/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt +++ b/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt @@ -349,11 +349,7 @@ class BookSourceActivity : VMBaseActivity viewModel.saveToFile(adapter.selection) { file -> exportDir.launch { mode = HandleFileContract.EXPORT - fileData = Triple( - "bookSource.json", - file.readBytes(), - "application/json" - ) + fileData = Triple("bookSource.json", file, "application/json") } } } diff --git a/app/src/main/java/io/legado/app/ui/document/HandleFileContract.kt b/app/src/main/java/io/legado/app/ui/document/HandleFileContract.kt index b33d2ef70..af2dda346 100644 --- a/app/src/main/java/io/legado/app/ui/document/HandleFileContract.kt +++ b/app/src/main/java/io/legado/app/ui/document/HandleFileContract.kt @@ -55,7 +55,7 @@ class HandleFileContract : var title: String? = null, var allowExtensions: Array = arrayOf(), var otherActions: ArrayList>? = null, - var fileData: Triple? = null, + var fileData: Triple? = null, var requestCode: Int = 0 )