mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-18 06:17:06 +00:00
fix: 修复无群名片时at带上了昵称的问题
This commit is contained in:
parent
7c36f9361e
commit
70472464cf
1 changed files with 6 additions and 2 deletions
|
|
@ -551,9 +551,13 @@ export class chatgpt extends plugin {
|
||||||
let me = mm.get(Bot.uin)
|
let me = mm.get(Bot.uin)
|
||||||
let card = me.card
|
let card = me.card
|
||||||
let nickname = me.nickname
|
let nickname = me.nickname
|
||||||
|
if (card) {
|
||||||
prompt = prompt.replace(`@${card}`, '').trim()
|
prompt = prompt.replace(`@${card}`, '').trim()
|
||||||
|
}
|
||||||
|
if (nickname) {
|
||||||
prompt = prompt.replace(`@${nickname}`, '').trim()
|
prompt = prompt.replace(`@${nickname}`, '').trim()
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
let ats = e.message.filter(m => m.type === 'at')
|
let ats = e.message.filter(m => m.type === 'at')
|
||||||
if (!e.atme && ats.length > 0) {
|
if (!e.atme && ats.length > 0) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue