From 7a8d88eb36c920a6c932289cb540d4e232e18d8c Mon Sep 17 00:00:00 2001 From: IITII Date: Wed, 6 Dec 2023 00:06:48 +0800 Subject: [PATCH] fix: clean useless words --- libs/download/sites/Eveira.js | 2 +- libs/download/sites/EveiraTags.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/libs/download/sites/Eveira.js b/libs/download/sites/Eveira.js index 7e6f456..9e45a27 100644 --- a/libs/download/sites/Eveira.js +++ b/libs/download/sites/Eveira.js @@ -15,7 +15,7 @@ module.exports = class Eveira extends AbsDownloader { return {url: el.attribs.href, text: $(el).text()} }).get(), tags = urlTextsToAbs(tagsR, original) - const rawImgs = $("#content figure img").map((i, el) => el.attribs['data-src'] || el.attribs['src']).get() + const rawImgs = $("#content .entry-content figure img").map((i, el) => el.attribs['data-src'] || el.attribs['src']).get() const absImgs = arrToAbsUrl(rawImgs, original), imgs = uniq(absImgs) // const imgs = await zipUrlExt(absImgs, getSaveDir(title)) diff --git a/libs/download/sites/EveiraTags.js b/libs/download/sites/EveiraTags.js index e171239..179b83c 100644 --- a/libs/download/sites/EveiraTags.js +++ b/libs/download/sites/EveiraTags.js @@ -39,6 +39,7 @@ module.exports = class EveiraTags extends AbsDownloader { const poster = $(el).find('img').get(0)?.attribs['data-src'] || $(el).find('img').get(0)?.attribs.src let text = $(el).find('img').get(0) text = text?.attribs.title || text?.attribs.alt + text = text.replace(/Read more about the article/, '').trim() return {url: el.attribs.href, text, poster} }).get() images = uniqUrlTexts(images)