Skip to content

Commit

Permalink
Fix «all but last message» bug
Browse files Browse the repository at this point in the history
  • Loading branch information
George V. Kouryachy (Fr. Br. George) committed May 20, 2024
1 parent 35c77e6 commit be29ac9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions hworker/deliver/imap/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ def download_all():

download_mails = 0

get_logger(__name__).info(f"Started downloading")

limit = get_imap_info()["letter_limit"]
get_logger(__name__).info(f"Started downloading up to {limit} messages")
for mail in tqdm(
box.fetch("ALL", limit=get_imap_info()["letter_limit"]),
box.fetch("ALL", limit=limit if limit > 0 else None),
colour="green",
desc="Imap download",
delay=2,
Expand Down

0 comments on commit be29ac9

Please sign in to comment.