mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-01-19 17:58:26 +08:00
🐛 fix remain space after reply
This commit is contained in:
parent
d55459cfcd
commit
9241f4df79
@ -118,6 +118,9 @@ async def _check_reply(bot: "Bot", event: "Event"):
|
|||||||
del event.message[index]
|
del event.message[index]
|
||||||
if len(event.message) > index and event.message[index].type == "at":
|
if len(event.message) > index and event.message[index].type == "at":
|
||||||
del event.message[index]
|
del event.message[index]
|
||||||
|
if len(event.message) > index and event.message[index].type == "test":
|
||||||
|
event.message[index].data["text"] = event.message[index].data[
|
||||||
|
"text"].strip()
|
||||||
if not event.message:
|
if not event.message:
|
||||||
event.message.append(MessageSegment.text(""))
|
event.message.append(MessageSegment.text(""))
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user