fix 全局变量定义

This commit is contained in:
jxxghp
2024-09-09 22:17:49 +08:00
parent f18b9793b4
commit c3ef3dd7d1
14 changed files with 88 additions and 87 deletions

View File

@@ -275,7 +275,8 @@ class QbittorrentModule(_ModuleBase, _DownloaderBase):
if not server:
return None
server.set_torrents_tag(ids=hashs, tags=['已整理'])
# 移动模式删除种子
# FIXME 移动模式删除种子
"""
if settings.TRANSFER_TYPE in ["move"]:
if self.remove_torrents(hashs):
logger.info(f"移动模式删除种子成功:{hashs} ")
@@ -285,6 +286,7 @@ class QbittorrentModule(_ModuleBase, _DownloaderBase):
if not files:
logger.warn(f"删除残留文件夹:{path}")
shutil.rmtree(path, ignore_errors=True)
"""
def remove_torrents(self, hashs: Union[str, list], delete_file: bool = True,
downloader: str = None) -> Optional[bool]: