Fix save img
This commit is contained in:
1 parent
1a0474420b
commit
97733ca337
1 file changed
+11
-10
@@ -210,18 +210,19 @@ class SpiderDen(private val mGalleryInfo: GalleryInfo) {
|
||||
it.printStackTrace()
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
downloadDir?.let { uniFile ->
|
||||
runCatching {
|
||||
findImageFile(uniFile, index)?.openFileDescriptor("r")?.use {
|
||||
it sendTo toFd
|
||||
}
|
||||
}.onFailure {
|
||||
it.printStackTrace()
|
||||
return false
|
||||
}.onSuccess {
|
||||
return true
|
||||
// Read from download dir
|
||||
downloadDir?.let { uniFile ->
|
||||
runCatching {
|
||||
findImageFile(uniFile, index)?.openFileDescriptor("r")?.use {
|
||||
it sendTo toFd
|
||||
}
|
||||
}.onFailure {
|
||||
it.printStackTrace()
|
||||
return false
|
||||
}.onSuccess {
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user