Skip to content

Commit 6ebbb44

Browse files
committed
fix: q2tg 新的 header,防止触发两次 bot
1 parent aff7ddc commit 6ebbb44

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

apps/qqbot/src/adapter/Bot.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,8 @@ export class BotAdapter extends Bot<BotTypes> {
136136
const at = data.message.find(it => it.type === 'at');
137137
const text = data.message.find(it => it.type === 'text')?.data.text.trim();
138138
if (!text) return;
139+
// q2tg 新的 header,防止触发两次 bot
140+
if (data.message.some(it => it.type === 'image')) return;
139141

140142
if ('group_id' in data && at && at.data.qq.toString() === this.env.OFFICIAL_BOT_UIN.toString()) {
141143
// 检查融合模式

0 commit comments

Comments
 (0)