From efd12dac350d34fef3a2039304ff43079a80bad2 Mon Sep 17 00:00:00 2001 From: zhayujie Date: Sat, 25 Mar 2023 02:54:46 +0800 Subject: [PATCH] fix: single reply in no prefix --- .gitignore | 3 ++- channel/wechat/wechat_channel.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index d8e0f73..d5178c6 100644 --- a/.gitignore +++ b/.gitignore @@ -8,4 +8,5 @@ config.json QR.png nohup.out tmp -plugins.json \ No newline at end of file +plugins.json +itchat.pkl diff --git a/channel/wechat/wechat_channel.py b/channel/wechat/wechat_channel.py index bc5faf9..dd7580d 100644 --- a/channel/wechat/wechat_channel.py +++ b/channel/wechat/wechat_channel.py @@ -95,7 +95,7 @@ class WechatChannel(Channel): return if match_prefix: content = content.replace(match_prefix, '', 1).strip() - else: + elif match_prefix is None: return context = Context() context.kwargs = {'isgroup': False, 'msg': msg, 'receiver': other_user_id, 'session_id': other_user_id}