From f998b39152b064eba1e919ef719db9c23e09d163 Mon Sep 17 00:00:00 2001 From: jxxghp Date: Sat, 9 Sep 2023 21:58:49 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E5=88=A0=E9=99=A4=E7=A7=8D=E5=AD=90?= =?UTF-8?q?=E6=95=B0=E6=97=A0=E6=B3=95=E8=AE=A1=E7=AE=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/plugins/brushflow/__init__.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/plugins/brushflow/__init__.py b/app/plugins/brushflow/__init__.py index a6f1d721..54f3c9b5 100644 --- a/app/plugins/brushflow/__init__.py +++ b/app/plugins/brushflow/__init__.py @@ -1242,7 +1242,8 @@ class BrushFlow(_PluginBase): torrents_size = 0 # 读取统计数据 statistic_info = self.get_data("statistic") or { - "count": 0 + "count": 0, + "deleted": 0, } # 处理所有站点 for siteid in self._brushsites: @@ -1500,6 +1501,8 @@ class BrushFlow(_PluginBase): continue # 统计删除状态 if remove_torrents: + if not statistic_info.get("deleted"): + statistic_info["deleted"] = 0 statistic_info["deleted"] += len(remove_torrents) # 删除任务记录 for torrent in remove_torrents: