From 337ac0eab99ceb4bdaebfcd0ae5833006be7dc8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=89=8B=E7=93=9C=E4=B8=80=E5=8D=81=E9=9B=AA?= Date: Sun, 25 Aug 2024 23:50:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E8=BF=87=E6=BB=A4=E6=97=A0=E6=95=88null?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/onebot/api/msg.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/onebot/api/msg.ts b/src/onebot/api/msg.ts index 834d1bd0..102956a8 100644 --- a/src/onebot/api/msg.ts +++ b/src/onebot/api/msg.ts @@ -717,7 +717,7 @@ export class OneBotMsgApi { const msgSegments = (await Promise.all(msg.elements.map( async (element) => { for (const key in element) { - if (keyCanBeParsed(key, this.rawToOb11Converters)) { + if (keyCanBeParsed(key, this.rawToOb11Converters) && this.rawToOb11Converters[key]) { return await this.rawToOb11Converters[key]?.( // eslint-disable-next-line // @ts-ignore