mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-16 13:27:08 +00:00
适配部分内容
This commit is contained in:
parent
abf6fa6ac2
commit
c82c137596
3 changed files with 6 additions and 3 deletions
|
|
@ -109,7 +109,8 @@ export class SendAudioMessageTool extends AbstractTool {
|
|||
groupList = e.bot.gl
|
||||
}
|
||||
try {
|
||||
if (groupList.get(target)) {
|
||||
if ((typeof groupList.get === 'function' && groupList.get(target)) ||
|
||||
(Array.isArray(groupList) && groupList.includes(target))) {
|
||||
let group = await e.bot.pickGroup(target)
|
||||
await group.sendMsg(sendable)
|
||||
return 'audio has been sent to group' + target
|
||||
|
|
|
|||
|
|
@ -34,7 +34,8 @@ export class SendAvatarTool extends AbstractTool {
|
|||
groupList = e.bot.gl
|
||||
}
|
||||
console.log('sendAvatar', target, pictures)
|
||||
if (groupList.get(target)) {
|
||||
if ((typeof groupList.get === 'function' && groupList.get(target)) ||
|
||||
(Array.isArray(groupList) && groupList.includes(target))) {
|
||||
let group = await e.bot.pickGroup(target)
|
||||
await group.sendMsg(pictures)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,7 +34,8 @@ export class SendMessageToSpecificGroupOrUserTool extends AbstractTool {
|
|||
groupList = e.bot.gl
|
||||
}
|
||||
try {
|
||||
if (groupList.get(target)) {
|
||||
if ((typeof groupList.get === 'function' && groupList.get(target)) ||
|
||||
(Array.isArray(groupList) && groupList.includes(target))) {
|
||||
let group = await e.bot.pickGroup(target)
|
||||
await group.sendMsg(await convertFaces(msg, true, e))
|
||||
return 'msg has been sent to group' + target
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue