fix: 哔滴影视优先返回种子链接 (#6735)

This commit is contained in:
Ethan Shen 2021-01-21 07:30:31 +08:00 committed by GitHub
parent 06d5a47903
commit 35afd7ad2a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -55,10 +55,10 @@ module.exports = async (ctx) => {
let downloadLinks = '';
for (const downloadLink of downloadResponse.data) {
downloadLinks += `<div class="item">${downloadLink.downloadCategory.name}: <a href="${downloadLink.url}">${downloadLink.url}</a></div>`;
downloadLinks += `<div class="item"><div class="content">${downloadLink.downloadCategory.name}: <a href="${downloadLink.url}">${downloadLink.url}</a></div></div>`;
}
const torrents = content('#download-wrapper').nextAll('.list').eq(0);
const torrents = content('#torrent-list .list');
item.description = content('.info0').html() + `<div><b>下载地址:</b>${downloadLinks}</div>` + `${torrents.html() ? `<div><b>种子列表:</b>${torrents.html()}</div>` : ''}`;
item.enclosure_url = torrents.html() ? torrents.find('a.header').last().attr('href') : downloadResponse.data.pop().url;