feat: wechatmp channel support voice/image reply

This commit is contained in:
JS00000
2023-04-20 10:26:58 +08:00
parent 34209021c8
commit a7772316f9
6 changed files with 164 additions and 44 deletions

View File

@@ -144,14 +144,14 @@ class ChatChannel(Channel):
context.type = ContextType.TEXT
context.content = content.strip()
if (
"desire_rtype" not in context
context["desire_rtype"] == None
and conf().get("always_reply_voice")
and ReplyType.VOICE not in self.NOT_SUPPORT_REPLYTYPE
):
context["desire_rtype"] = ReplyType.VOICE
elif context.type == ContextType.VOICE:
if (
"desire_rtype" not in context
context["desire_rtype"] == None
and conf().get("voice_reply_voice")
and ReplyType.VOICE not in self.NOT_SUPPORT_REPLYTYPE
):