regex fix

This commit is contained in:
imDMG 2019-01-31 18:33:55 +00:00 committed by GitHub
parent 66270f4ee4
commit 7e7520d39c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -130,7 +130,7 @@ class nnmclub(object):
response = self._catch_error_request(query)
page = response.read().decode('cp1251')
self.draw(page)
total = int(re.search(r'\(max:\s(\d{1,3})\)', page)[1]) if first else -1
total = int(re.search(r'(\d{1,3})\s\(max:', page)[1]) if first else -1
return total