feat: 支持检测群内禁言

This commit is contained in:
Rock Chin
2023-04-24 10:34:51 +08:00
parent 5b96ac122f
commit 3cb49fe2d8
3 changed files with 24 additions and 14 deletions

View File

@@ -66,7 +66,8 @@ def process_message(launcher_type: str, launcher_id: int, text_message: str, mes
# 检查是否被禁言
if launcher_type == 'group':
if mgr.adapter.is_muted(launcher_id):
is_muted = mgr.adapter.is_muted(launcher_id)
if is_muted:
logging.info("机器人被禁言,跳过消息处理(group_{})".format(launcher_id))
return reply