From 08a3d02daf0783803fa8a363ddd2b315055214eb Mon Sep 17 00:00:00 2001 From: jxxghp Date: Sun, 3 Sep 2023 17:37:06 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E8=B0=83=E6=95=B4=E9=87=8D=E6=96=B0?= =?UTF-8?q?=E6=95=B4=E7=90=86=E7=9A=84=E5=88=A0=E9=99=A4=E9=A1=BA=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/chain/transfer.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/chain/transfer.py b/app/chain/transfer.py index b92849a4..0a44e45a 100644 --- a/app/chain/transfer.py +++ b/app/chain/transfer.py @@ -464,6 +464,10 @@ class TransferChain(ChainBase): # 更新媒体图片 self.obtain_images(mediainfo=mediainfo) + # 删除旧的已整理文件 + if history.dest: + self.delete_files(Path(history.dest)) + # 转移 state, errmsg = self.do_transfer(path=src_path, mediainfo=mediainfo, @@ -471,10 +475,6 @@ class TransferChain(ChainBase): if not state: return False, errmsg - # 删除旧的已整理文件 - if history.dest: - self.delete_files(Path(history.dest)) - # 删除旧历史记录 self.transferhis.delete(logid)