From 62e643acf8e4f7f311746635de08cb7242966c8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E4=B8=80=E4=B9=8B?= Date: Fri, 13 Sep 2024 14:00:41 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E7=BB=95=E8=BF=87=E8=AE=A4=E8=AF=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/main.py | 1 - app/scheduler.py | 1 - app/schemas/plugin.py | 2 +- 3 files changed, 1 insertion(+), 3 deletions(-) diff --git a/app/main.py b/app/main.py index 8891819e..5a2ee2bf 100644 --- a/app/main.py +++ b/app/main.py @@ -157,7 +157,6 @@ def check_auth(): """ 检查认证状态 """ - SitesHelper().auth_level = 3 if SitesHelper().auth_level < 2: err_msg = "用户认证失败,站点相关功能将无法使用!" MessageHelper().put(f"注意:{err_msg}", title="用户认证", role="system") diff --git a/app/scheduler.py b/app/scheduler.py index fa0fe89a..81679d1d 100644 --- a/app/scheduler.py +++ b/app/scheduler.py @@ -72,7 +72,6 @@ class Scheduler(metaclass=Singleton): """ 用户认证检查 """ - SitesHelper().auth_level = 3 if SitesHelper().auth_level >= 2: return # 最大重试次数 diff --git a/app/schemas/plugin.py b/app/schemas/plugin.py index 742ff1a7..1277b0e4 100644 --- a/app/schemas/plugin.py +++ b/app/schemas/plugin.py @@ -27,7 +27,7 @@ class Plugin(BaseModel): # 加载顺序 plugin_order: Optional[int] = 0 # 可使用的用户级别 - auth_level: Optional[int] = 0 + auth_level: Optional[int] = 3 # 是否已安装 installed: Optional[bool] = False # 运行状态