fix(download): Making sure archive tmp file is created properly
(cherry picked from commit fc87410d46ed4a44a44ad74870c9fe13214581b0)
This commit is contained in:
parent
3609e3ec92
commit
eddabbc04e
1 changed files with 2 additions and 1 deletions
|
|
@ -630,7 +630,8 @@ class Downloader(
|
|||
val encrypt = CbzCrypto.getPasswordProtectDlPref() && CbzCrypto.isPasswordSet()
|
||||
// SY <--
|
||||
|
||||
val zip = mangaDir.createFile("$dirname.cbz$TMP_DIR_SUFFIX")!!
|
||||
val zip = mangaDir.createFile("$dirname.cbz$TMP_DIR_SUFFIX")
|
||||
if (zip?.isFile != true) throw Exception("Failed to create CBZ file for downloaded chapter")
|
||||
ZipWriter(context, zip, /* SY --> */ encrypt /* SY <-- */).use { writer ->
|
||||
tmpDir.listFiles()?.forEach { file ->
|
||||
writer.write(file)
|
||||
|
|
|
|||
Loading…
Reference in a new issue