This commit is contained in:
caiwx86 2022-12-21 01:34:08 +08:00
parent 41e9cc4eec
commit 1a17ea9d17
2 changed files with 7 additions and 2 deletions

View File

@ -58,8 +58,13 @@ class CBZUtils:
try:
size_zip = cls.zip_compression(chapter_path,packCBZ_path+".CBZ")
size_imgs = len(comicInfo.getChapterImgs())
if size_zip -1 == size_zip:
if size_zip -1 == size_imgs:
ntfy.sendMsg(f"打包校验成功: {packCBZ_path}")
return True
else:
ntfy.sendMsg(f"打包检验不完整:{packCBZ_path}")
return False
except:
ntfy.sendMsg("CBZ打包失败")
comicInfo.nextCBZToDoneChapter()

View File

@ -119,7 +119,7 @@ class comicEntity:
if comicInfo.nextExistsGetPath("cbz_"):
time.sleep(1)
#下载后自动打包
CBZUtils.packAutoComicChapterCBZ()
is_next = CBZUtils.packAutoComicChapterCBZ()
#完成删除原文件
remove_path = comicInfo.getDirComicChapter()
shutil.rmtree(remove_path)