Skip to content

Commit

Permalink
decodes plaintext automatically fixes #64
Browse files Browse the repository at this point in the history
  • Loading branch information
geek-at committed Nov 22, 2023
1 parent 87404cc commit 85f7b30
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/mailserver3.py
Expand Up @@ -56,7 +56,7 @@ async def handle_DATA(self, server, session, envelope):
return '500 Attachment too large. Max size: ' + str(ATTACHMENTS_MAX_SIZE/1000000)+"MB"
attachments['file%d' % len(attachments)] = att
else:
plaintext += part.get_payload()
plaintext += part.get_payload(decode=True).decode('utf-8')
elif part.get_content_type() == 'text/html':
html += part.get_payload()
else:
Expand Down

0 comments on commit 85f7b30

Please sign in to comment.