From 308d8af55921c4d85219c8c254f6a78106202b69 Mon Sep 17 00:00:00 2001 From: student_2333 Date: Wed, 30 Oct 2024 00:23:05 +0800 Subject: [PATCH] fix --- nonebot_plugin_nailongremove/__init__.py | 2 +- nonebot_plugin_nailongremove/handler.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/nonebot_plugin_nailongremove/__init__.py b/nonebot_plugin_nailongremove/__init__.py index a3d895e..a3f4c14 100644 --- a/nonebot_plugin_nailongremove/__init__.py +++ b/nonebot_plugin_nailongremove/__init__.py @@ -9,7 +9,7 @@ from . import handler as handler from .config import Config -__version__ = "2.1.1" +__version__ = "2.1.1.post1" __plugin_meta__ = PluginMetadata( name="自动撤回奶龙", description="一个基于图像分类模型的简单插件~", diff --git a/nonebot_plugin_nailongremove/handler.py b/nonebot_plugin_nailongremove/handler.py index a27169f..cbb874c 100644 --- a/nonebot_plugin_nailongremove/handler.py +++ b/nonebot_plugin_nailongremove/handler.py @@ -139,8 +139,8 @@ async def wait_result(): return ok for f in frames: - if (sem.locked() or signal.done()) and (await wait_result()): - return True, None + if (sem.locked() or signal.done()) and (r := await wait_result())[0]: + return r asyncio.create_task(task(f)) return await wait_result()