From c8374474c676fd256356e73e94e18335abfcb010 Mon Sep 17 00:00:00 2001 From: Tobias Gruetzmacher Date: Mon, 20 Apr 2020 00:49:53 +0200 Subject: [PATCH] Remove _TumblrScraper (no modules uses it anymore) --- dosagelib/plugins/common.py | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/dosagelib/plugins/common.py b/dosagelib/plugins/common.py index 0bcc2f68e..37662eb63 100644 --- a/dosagelib/plugins/common.py +++ b/dosagelib/plugins/common.py @@ -39,20 +39,3 @@ class _ComicControlScraper(_ParserScraper): prevSearch = '//a[@rel="prev"]' nextSearch = '//a[@rel="next"]' latestSearch = '//a[@rel="last"]' - - -class _TumblrScraper(_ParserScraper): - starter = indirectStarter - - def namer(self, image_url, page_url): - # tumblr URLs: http://host/post/num/name - # 0 1 2 3 4 5 - parts = page_url.split('/') - if len(parts) > 5: - return '%s_%s' % (parts[4], parts[5]) - else: - return parts[4] - - def shouldSkipUrl(self, url, data): - """Reblogged stuff is iframed""" - return data.xpath('//div[@id="post"]//iframe')