From bf1896f959536591e7ed930af275e587f7f670ad Mon Sep 17 00:00:00 2001 From: Rock Chin <1010553892@qq.com> Date: Sat, 25 Feb 2023 10:47:52 +0800 Subject: [PATCH] =?UTF-8?q?fix(process):=20=E5=88=A4=E6=96=AD=E6=B6=88?= =?UTF-8?q?=E6=81=AF=E7=B1=BB=E5=9E=8B=E6=97=B6=E7=9A=84=E6=95=B0=E7=BB=84?= =?UTF-8?q?=E8=B6=8A=E7=95=8C=E9=A3=8E=E9=99=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkg/qqbot/process.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/qqbot/process.py b/pkg/qqbot/process.py index 00785b64..2b1aed5f 100644 --- a/pkg/qqbot/process.py +++ b/pkg/qqbot/process.py @@ -138,7 +138,7 @@ def process_message(launcher_type: str, launcher_id: int, text_message: str, mes if hasattr(config, "rate_limitation"): ratelimit.add_usage(session_name) - if reply is not None and (type(reply[0]) == str or type(reply[0]) == mirai.Plain): + if reply is not None and len(reply) > 0 and (type(reply[0]) == str or type(reply[0]) == mirai.Plain): logging.info( "回复[{}]文字消息:{}".format(session_name, reply[0][:min(100, len(reply[0]))] + (