feat: disable plugin when init failed

This commit is contained in:
lanvent
2023-04-05 18:05:28 +08:00
parent 2cf71dd6f2
commit 5bd9f50818
6 changed files with 21 additions and 11 deletions

View File

@@ -48,7 +48,7 @@ class ChatChannel(Channel):
if first_in: # context首次传入时receiver是None根据类型设置receiver
config = conf()
cmsg = context['msg']
if cmsg.from_user_id == self.user_id and not config.get('trigger_by_self', False):
if cmsg.from_user_id == self.user_id and not config.get('trigger_by_self', True):
logger.debug("[WX]self message skipped")
return None
if context["isgroup"]: