Fix max page number determination.
This commit is contained in:
parent
fade3c20fc
commit
cf310894b5
|
@ -187,8 +187,7 @@ class BotInstance:
|
|||
# Get a random image making sure it's not in the saved image list
|
||||
while True:
|
||||
image_url, image_src, image_rating, cur_page_number = self.get_random_image(max_page_number=self.max_page_number)
|
||||
if cur_page_number < self.max_page_number:
|
||||
self.max_page_number = cur_page_number
|
||||
self.max_page_number = cur_page_number
|
||||
if image_url is None:
|
||||
continue
|
||||
break
|
||||
|
|
Loading…
Reference in New Issue