Favour the first image we found when we're not expecting multiple images
This commit is contained in:
parent
8d84361de4
commit
a83911aa67
1 changed files with 1 additions and 1 deletions
|
@ -142,7 +142,7 @@ class Scraper(object):
|
||||||
out.warn(
|
out.warn(
|
||||||
u"Found %d images instead of 1 at %s with expressions %s" %
|
u"Found %d images instead of 1 at %s with expressions %s" %
|
||||||
(len(imageUrls), url, prettyMatcherList(self.imageSearch)))
|
(len(imageUrls), url, prettyMatcherList(self.imageSearch)))
|
||||||
image = sorted(imageUrls)[0]
|
image = imageUrls[0]
|
||||||
out.warn(u"Choosing image %s" % image)
|
out.warn(u"Choosing image %s" % image)
|
||||||
imageUrls = (image,)
|
imageUrls = (image,)
|
||||||
elif not imageUrls:
|
elif not imageUrls:
|
||||||
|
|
Loading…
Reference in a new issue