From d6e2cab5ef2646bac98e10ca6b111c4e9bb4361b Mon Sep 17 00:00:00 2001 From: honue Date: Sat, 28 Oct 2023 18:40:27 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=BC=E5=AE=B91.3.7=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E6=B8=85=E7=90=86=E6=8F=92=E4=BB=B6=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/plugins/autoclean/__init__.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/app/plugins/autoclean/__init__.py b/app/plugins/autoclean/__init__.py index 813261a9..5a10038c 100644 --- a/app/plugins/autoclean/__init__.py +++ b/app/plugins/autoclean/__init__.py @@ -137,6 +137,16 @@ class AutoClean(_PluginBase): clean_type = self._cleantype clean_date = self._cleandate + # 1.3.7版本及之前处理多位用户 + if str(self._cleanuser).count(','): + for username in str(self._cleanuser).split(","): + downloadhis_list = self._downloadhis.list_by_user_date(date=clean_date, + username=username) + logger.info( + f'获取到用户 {username} 日期 {clean_date} 之前的下载历史 {len(downloadhis_list)} 条') + self.__clean_history(date=clean_date, clean_type=self._cleantype, downloadhis_list=downloadhis_list) + return + for userinfo in str(self._cleanuser).split("\n"): if userinfo.count('#'): clean_type = userinfo.split('#')[1]