Closed woutervh closed 8 years ago
It seems easy to just add in imapy/email_message.py
elif content_type == 'text/html':
# convert html
html = utils.b_to_str(part.get_payload(decode=True))
self['html'].append(html)
else:
attachment = {'filename': part.get_filename(),
'data': utils.b_to_str(part.get_payload(decode=True)),
'content_type': content_type, }
self['attachments'].append(attachment)
Fixed in 1.1.0
Using imapy 1.0.3 on python 2.7.10:
there seem no way to access attachments?
for example when you have a pdf-file in attachment, the content-type is 'application/pdf', but in imapy/email_message.py only 'text/plain' and 'text/html' are handled.