From 1cc9d501ab5f719b07cb12ba0d204a867136c8ad Mon Sep 17 00:00:00 2001 From: Alen Date: Sun, 18 Aug 2024 14:33:35 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20API=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 优化get_group_member_info在查询非群员时的效率 --- src/common/framework/event-legacy.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/common/framework/event-legacy.ts b/src/common/framework/event-legacy.ts index 136ead80..66092943 100644 --- a/src/common/framework/event-legacy.ts +++ b/src/common/framework/event-legacy.ts @@ -232,6 +232,11 @@ export class LegacyNTEventWrapper { this.createListenerFunction(ListenerMainName); const EventFunc = this.createEventFunction(EventName); retEvent = await EventFunc!(...(args as any[])); + // 120271006: TaskGetGroupMemberList 0x899_EMPTY_RSP_BODY 查找群内不存在的成员返回 + if (typeof retEvent === 'object' && retEvent?.result !== 0) { + clearTimeout(Timeouter); + databack(); + }; }, ); }