Fix Dilbert image naming.

This commit is contained in:
Bastian Kleineidam 2013-03-18 18:15:19 +01:00
parent 3fdcd7c057
commit 178d8f80b2
2 changed files with 7 additions and 1 deletions

View file

@ -13,6 +13,10 @@ Changes:
- comics: Continue searching for images if one image is not found.
Closes: GH bug #18
Fixes:
- comics: Fix dilbert image naming.
Closes: GH bug #20
Dosage 1.13 (released 11.3.2013)

View file

@ -5,7 +5,7 @@
from re import compile
from ..scraper import _BasicScraper
from ..helpers import indirectStarter
from ..helpers import indirectStarter, bounceStarter
from ..util import tagre
@ -107,6 +107,8 @@ class DieselSweeties(_BasicScraper):
class Dilbert(_BasicScraper):
url = 'http://dilbert.com/'
stripUrl = url + '%s/'
starter = bounceStarter(url,
compile(tagre("a", "href", r'(/\d+-\d+-\d+/)', after="STR_Next")))
prevSearch = compile(tagre("a", "href", r'(/\d+-\d+-\d+/)', after="STR_Prev"))
imageSearch = compile(tagre("img", "src", r'(/dyn/str_strip/[^"]+\.strip\.zoom\.gif)'))
help = 'Index format: yyyy-mm-dd'