口癖和正文之间添加空格, 防止链接显示错误

This commit is contained in:
biupiaa 2025-01-22 11:02:32 +08:00 committed by GitHub
parent d0b1024566
commit 478238f4b8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -21,7 +21,7 @@ async def handle_api_call(bot: Bot, api: str, data: dict[str, Any]):
if catchphrase and (message := data.get("message")):
for i in range(len(message) - 1, -1, -1):
if message[i].type == "text":
message[i].data["text"] += catchphrase
message[i].data["text"] = f"{message[i].data['text']} {catchphrase}"
logger.debug(
f"文本: {message[i].data['text']} 添加口癖: {catchphrase}"
)