mirror of
https://github.com/Jerryplusy/rc-plugin.git
synced 2025-10-14 16:19:18 +00:00
commit
b287cfa535
@ -19,7 +19,7 @@ export class songRequest extends plugin {
|
|||||||
priority: 300,
|
priority: 300,
|
||||||
rule: [
|
rule: [
|
||||||
{
|
{
|
||||||
reg: '^#?点歌|#?听[1-9][0-9]*|#?听[1-9]*$',
|
reg: '^#点歌|#?听[1-9][0-9]*|#?听[1-9]*$',
|
||||||
fnc: 'pickSong'
|
fnc: 'pickSong'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -362,12 +362,12 @@ export class songRequest extends plugin {
|
|||||||
}
|
}
|
||||||
// 发送群文件
|
// 发送群文件
|
||||||
await this.uploadGroupFile(e, path);
|
await this.uploadGroupFile(e, path);
|
||||||
// 删除文件
|
|
||||||
await checkAndRemoveFile(path);
|
|
||||||
// 发送语音
|
// 发送语音
|
||||||
if (musicExt != 'mp4' && this.isSendVocal) {
|
if (musicExt != 'mp4' && this.isSendVocal) {
|
||||||
await e.reply(segment.record(path));
|
await e.reply(segment.record(path));
|
||||||
}
|
}
|
||||||
|
// 删除文件
|
||||||
|
await checkAndRemoveFile(path);
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
logger.error(`下载音乐失败,错误信息为: ${err}`);
|
logger.error(`下载音乐失败,错误信息为: ${err}`);
|
||||||
|
@ -1841,12 +1841,12 @@ export class tools extends plugin {
|
|||||||
downloadAudio(url, this.getCurDownloadPath(e), title, 'follow', musicExt).then(async path => {
|
downloadAudio(url, this.getCurDownloadPath(e), title, 'follow', musicExt).then(async path => {
|
||||||
// 发送群文件
|
// 发送群文件
|
||||||
await this.uploadGroupFile(e, path);
|
await this.uploadGroupFile(e, path);
|
||||||
// 删除文件
|
|
||||||
await checkAndRemoveFile(path);
|
|
||||||
// 发送语音
|
// 发送语音
|
||||||
if (musicExt != 'mp4' && this.isSendVocal) {
|
if (musicExt != 'mp4' && this.isSendVocal) {
|
||||||
await e.reply(segment.record(path));
|
await e.reply(segment.record(path));
|
||||||
}
|
}
|
||||||
|
// 删除文件
|
||||||
|
await checkAndRemoveFile(path);
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
logger.error(`下载音乐失败,错误信息为: ${err}`);
|
logger.error(`下载音乐失败,错误信息为: ${err}`);
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user