mirror of
https://github.com/Jerryplusy/rc-plugin.git
synced 2025-10-14 08:09:19 +00:00
🐞 fix: 修复解析后发送语音错误
This commit is contained in:
parent
46a1c87f6f
commit
b1f93c6be1
@ -362,12 +362,12 @@ export class songRequest extends plugin {
|
||||
}
|
||||
// 发送群文件
|
||||
await this.uploadGroupFile(e, path);
|
||||
// 删除文件
|
||||
await checkAndRemoveFile(path);
|
||||
// 发送语音
|
||||
if (musicExt != 'mp4' && this.isSendVocal) {
|
||||
await e.reply(segment.record(path));
|
||||
}
|
||||
// 删除文件
|
||||
await checkAndRemoveFile(path);
|
||||
}
|
||||
}).catch(err => {
|
||||
logger.error(`下载音乐失败,错误信息为: ${err}`);
|
||||
|
@ -1841,12 +1841,12 @@ export class tools extends plugin {
|
||||
downloadAudio(url, this.getCurDownloadPath(e), title, 'follow', musicExt).then(async path => {
|
||||
// 发送群文件
|
||||
await this.uploadGroupFile(e, path);
|
||||
// 删除文件
|
||||
await checkAndRemoveFile(path);
|
||||
// 发送语音
|
||||
if (musicExt != 'mp4' && this.isSendVocal) {
|
||||
await e.reply(segment.record(path));
|
||||
}
|
||||
// 删除文件
|
||||
await checkAndRemoveFile(path);
|
||||
}).catch(err => {
|
||||
logger.error(`下载音乐失败,错误信息为: ${err}`);
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user