Remove prevUrlMatchesStripUrl.
It was only used for one test.
This commit is contained in:
parent
92a688457a
commit
ee99c087d7
3 changed files with 1 additions and 8 deletions
|
@ -72,12 +72,9 @@ def add(name, url, adult, bounce):
|
||||||
url = url,
|
url = url,
|
||||||
starter = _starter,
|
starter = _starter,
|
||||||
prevUrlModifier = lambda cls, url: modifier(url),
|
prevUrlModifier = lambda cls, url: modifier(url),
|
||||||
stripUrl = url + '%s/',
|
|
||||||
imageSearch = _imageSearch,
|
imageSearch = _imageSearch,
|
||||||
prevSearch = _prevSearch,
|
prevSearch = _prevSearch,
|
||||||
prevUrlMatchesStripUrl = not adult,
|
|
||||||
lang = 'es' if name.lower().endswith('spanish') else 'en',
|
lang = 'es' if name.lower().endswith('spanish') else 'en',
|
||||||
help = 'Index format: nnnn (some increasing number)',
|
|
||||||
namer = namer,
|
namer = namer,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -54,10 +54,6 @@ class Scraper(object):
|
||||||
# if more than one image per URL is expected
|
# if more than one image per URL is expected
|
||||||
multipleImagesPerStrip = False
|
multipleImagesPerStrip = False
|
||||||
|
|
||||||
# set to False if previous URLs do not match the strip URL (ie. because of
|
|
||||||
# redirects)
|
|
||||||
prevUrlMatchesStripUrl = True
|
|
||||||
|
|
||||||
# set to True if this comic contains adult content
|
# set to True if this comic contains adult content
|
||||||
adult = False
|
adult = False
|
||||||
|
|
||||||
|
|
|
@ -60,7 +60,7 @@ def _test_comic(outdir, scraperobj):
|
||||||
for strip in scraperobj.getStrips(MaxStrips):
|
for strip in scraperobj.getStrips(MaxStrips):
|
||||||
_check_strip(outdir, strip, scraperobj.multipleImagesPerStrip)
|
_check_strip(outdir, strip, scraperobj.multipleImagesPerStrip)
|
||||||
|
|
||||||
if num_strips > 0 and scraperobj.prevUrlMatchesStripUrl:
|
if num_strips > 0:
|
||||||
_check_stripurl(strip, scraperobj)
|
_check_stripurl(strip, scraperobj)
|
||||||
num_strips += 1
|
num_strips += 1
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue