haran

Results 2 comments of haran

不用添加正则的,原来的代码里已经有正则校验啦,把那个mentionSelf()的if判断逻辑去掉就行啦 haran ***@***.***   ------------------ 原始邮件 ------------------ 发件人: "AutumnWhj/ChatGPT-wechat-bot" ***@***.***>; 发送时间: 2023年2月10日(星期五) 晚上9:45 ***@***.***>; ***@***.******@***.***>; 主题: Re: [AutumnWhj/ChatGPT-wechat-bot] 群自动回复失效fix (Issue #173) HIgdB,大佬好,求助一下,这个正则匹配是添加到哪个文件里面的啊... 纯小白卡在群聊这个环节了 - -! — Reply to this email directly, view it on...

> const pattern = RegExp(`^@${receiver.name()}`); if (pattern.test(content)) { const groupContent = content.replace(pattern, ''); replyMessage(room, groupContent); return; } else { console.log( 'Content is not within the scope of the customizition format...