Fix xkcd (closes #3), remove adult tag (fixes wummel#85).
This commit is contained in:
parent
19ec8f4dbe
commit
974752951b
1 changed files with 2 additions and 3 deletions
|
@ -14,12 +14,11 @@ class xkcd(_BasicScraper):
|
||||||
starter = bounceStarter(url, compile(tagre("a", "href", r'(/\d+/)', before="next")))
|
starter = bounceStarter(url, compile(tagre("a", "href", r'(/\d+/)', before="next")))
|
||||||
stripUrl = url + '%s/'
|
stripUrl = url + '%s/'
|
||||||
firstStripUrl = stripUrl % '1'
|
firstStripUrl = stripUrl % '1'
|
||||||
imageSearch = compile(tagre("img", "src", r'(http://imgs\.xkcd\.com/comics/[^"]+)'))
|
imageSearch = compile(tagre("img", "src", r'(//imgs\.xkcd\.com/comics/[^"]+)'))
|
||||||
prevSearch = compile(tagre("a", "href", r'(/\d+/)', before="prev"))
|
prevSearch = compile(tagre("a", "href", r'(/\d+/)', before="prev"))
|
||||||
help = 'Index format: n (unpadded)'
|
help = 'Index format: n (unpadded)'
|
||||||
description = u'A webcomic of romance, sarcasm, math, and language.'
|
description = u'A webcomic of romance, sarcasm, math, and language.'
|
||||||
textSearch = compile(tagre("img", "title", r'([^"]+)', before=r'http://imgs\.xkcd\.com/comics/'))
|
textSearch = compile(tagre("img", "title", r'([^"]+)', before=r'//imgs\.xkcd\.com/comics/'))
|
||||||
adult = True
|
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def namer(cls, imageUrl, pageUrl):
|
def namer(cls, imageUrl, pageUrl):
|
||||||
|
|
Loading…
Reference in a new issue