From 49ec3cc3fa9712d27171993e6cc95e893aa14208 Mon Sep 17 00:00:00 2001 From: Tobias Gruetzmacher Date: Sat, 14 Jul 2018 11:00:27 +0200 Subject: [PATCH] Fix (and simplify) GoComics expressions (fixes #117) --- dosagelib/plugins/gocomics.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/dosagelib/plugins/gocomics.py b/dosagelib/plugins/gocomics.py index c7e7f481d..bf1c5230c 100644 --- a/dosagelib/plugins/gocomics.py +++ b/dosagelib/plugins/gocomics.py @@ -11,11 +11,9 @@ from ..helpers import indirectStarter, xpath_class class GoComics(_ParserScraper): url = 'http://www.gocomics.com/' - imageSearch = '//picture[{0}]/img'.format(xpath_class('item-comic-image')) - navSearch = '//div[{0}]//a[{1}]' - prevSearch = navSearch.format(xpath_class('comic'), xpath_class('fa-caret-left')) - nextSearch = navSearch.format(xpath_class('comic'), xpath_class('fa-caret-right')) - latestSearch = navSearch.format(xpath_class('gc-deck--cta-0'), xpath_class('')) + imageSearch = '//picture[{}]/img'.format(xpath_class('item-comic-image')) + prevSearch = '//a[{}]'.format(xpath_class('js-previous-comic')) + latestSearch = '//div[{}]//a'.format(xpath_class('gc-deck--cta-0')) starter = indirectStarter help = 'Index format: yyyy/mm/dd'