From 8efeb169afb1b449c40262c4fa035319d17ebd8c Mon Sep 17 00:00:00 2001 From: lyswhut Date: Sat, 9 Jan 2021 21:10:58 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=AD=8C=E6=9B=B2=E5=8C=B9?= =?UTF-8?q?=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/renderer/utils/music/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/renderer/utils/music/index.js b/src/renderer/utils/music/index.js index 81240ab8..2444eb1a 100644 --- a/src/renderer/utils/music/index.js +++ b/src/renderer/utils/music/index.js @@ -62,7 +62,7 @@ export default { for (const source of sources.sources) { if (!sources[source.id].musicSearch || source.id === musicInfo.source || source.id === 'xm') continue - tasks.push(sources[source.id].musicSearch.search(`${musicInfo.name} ${musicInfo.singer || ''} ${musicInfo.albumName || ''}`.trim(), 1, { limit: 5 }).then(res => { + tasks.push(sources[source.id].musicSearch.search(`${musicInfo.name} ${musicInfo.singer || ''}`.trim(), 1, { limit: 10 }).then(res => { for (const item of res.list) { if ( ( @@ -80,7 +80,7 @@ export default { return null }).catch(_ => null)) } - const result = (await Promise.all(tasks)).filter(s => s) + const result = (await Promise.all(tasks)).filter(s => s).reverse() const newResult = [] if (result.length) { for (let i = result.length - 1; i > -1; i--) {