Merge pull request #210 from RaubJo/patch-1

Update read_unread_emails.py
This commit is contained in:
streetturtle 2020-12-17 15:19:47 -05:00 committed by GitHub
commit 28256cd21c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -24,7 +24,7 @@ def process_mailbox(M):
local_date = datetime.datetime.fromtimestamp(email.utils.mktime_tz(date_tuple)) local_date = datetime.datetime.fromtimestamp(email.utils.mktime_tz(date_tuple))
print("{}: {}".format(header, local_date.strftime("%a, %d %b %Y %H:%M:%S"))) print("{}: {}".format(header, local_date.strftime("%a, %d %b %Y %H:%M:%S")))
else: else:
print('{}: {}'.format(header, hdr) print('{}: {}'.format(header, hdr))
# with code below you can process text of email # with code below you can process text of email
# if msg.is_multipart(): # if msg.is_multipart():
# for payload in msg.get_payload(): # for payload in msg.get_payload():