图片链接获取错误 #5681
This commit is contained in:
Quan 2020-12-23 20:49:51 +08:00 committed by GitHub
parent 5c4a293d53
commit b2d40539f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -19,7 +19,7 @@ module.exports = async (ctx) => {
item: list
.map((index, item) => {
item = $(item);
thumbnail_url = 'https:' + `${item.find('a > img').attr('data-original')}`;
thumbnail_url = 'https:' + `${ item.find('a > img').attr('src') ? item.find('a > img').attr('src') : item.find('a > img').attr('data-original') }`;
link_url = 'https://wnacg.org' + `${item.find('a').attr('href')}`;
return {
title: item.find('a').attr('title'),