From 2b7ca3f30ccf2b3b4d1c9c41cc0b3363ec2fdf15 Mon Sep 17 00:00:00 2001 From: Tobias Gruetzmacher Date: Sun, 26 May 2024 15:26:54 +0200 Subject: [PATCH] ComicsKingdom: Use more reliable source for full-size image (fixes #323) --- dosagelib/plugins/comicskingdom.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/dosagelib/plugins/comicskingdom.py b/dosagelib/plugins/comicskingdom.py index 82a1aea40..372cf8933 100644 --- a/dosagelib/plugins/comicskingdom.py +++ b/dosagelib/plugins/comicskingdom.py @@ -1,15 +1,13 @@ # SPDX-License-Identifier: MIT # SPDX-FileCopyrightText: © 2019 Tobias Gruetzmacher # SPDX-FileCopyrightText: © 2019 Thomas W. Littauer -from urllib.parse import parse_qs, urlsplit - from ..helpers import indirectStarter from ..scraper import ParserScraper class ComicsKingdom(ParserScraper): partDiv = '//div[d:class("comic-reader-item")]' - imageSearch = partDiv + '[1]//a[contains(@href, "/custom-framed-print/")]' + imageSearch = '//meta[@property="og:image"]/@content' prevSearch = partDiv + '[2]/@data-link' starter = indirectStarter help = 'Index format: yyyy-mm-dd' @@ -22,10 +20,6 @@ class ComicsKingdom(ParserScraper): if lang: self.lang = lang - def imageUrlModifier(self, url, data): - """Extract high-quality image URL from link""" - return parse_qs(urlsplit(url).query)['img'][0] - def link_modifier(self, fromurl, tourl): return tourl.replace('//wp.', '//', 1)