mirror of
https://github.com/vale981/kindle_fetch
synced 2025-03-04 08:31:38 -05:00
make regex slightly more robust
This commit is contained in:
parent
8a1c30198f
commit
d443b0e239
1 changed files with 1 additions and 1 deletions
|
@ -63,7 +63,7 @@ def get_download_link(text):
|
|||
text = quopri.decodestring(text).decode("utf-8", errors="ignore")
|
||||
logger.debug(text)
|
||||
|
||||
m = re.search(r'''href="(https://.*\.amazon\..*?)"''', text)
|
||||
m = re.search(r'''href="(https://.*\.amazon\..*\.pdf.*?)"''', text)
|
||||
if not m:
|
||||
return None, None
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue