1
0
Fork 0
mirror of https://github.com/kemayo/leech synced 2025-12-06 16:33:16 +01:00

Add output mentioning when an image is cached

This commit is contained in:
David Lynch 2024-11-23 22:34:04 -06:00
parent d49d7891c3
commit 6988fc8ccc

View file

@ -113,6 +113,8 @@ def chapter_html(
content_type=img_contents[2] content_type=img_contents[2]
)) ))
already_fetched_images[img['src']] = f"../images/ch{i}_leechimage_{count}.{img_contents[1]}" already_fetched_images[img['src']] = f"../images/ch{i}_leechimage_{count}.{img_contents[1]}"
else:
print(img['src'], "(already", already_fetched_images.get(img['src']), ")")
img['src'] = already_fetched_images.get(img['src']) img['src'] = already_fetched_images.get(img['src'])
if not img.has_attr('alt'): if not img.has_attr('alt'):