From 8939d7a28202898a2ff321e009b85f8bef3da115 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Lima?= Date: Thu, 14 Aug 2014 00:30:41 +0100 Subject: [PATCH] Support 'inline' Content Disposition --- imbox/parser.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/imbox/parser.py b/imbox/parser.py index d4b4d96..7682be4 100644 --- a/imbox/parser.py +++ b/imbox/parser.py @@ -114,9 +114,9 @@ def parse_email(raw_email): content_type = part.get_content_type() content_disposition = part.get('Content-Disposition', None) - if content_type == "text/plain" and content_disposition == None: - body['plain'].append(content) - elif content_type == "text/html" and content_disposition == None: + if content_type == "text/plain" and (content_disposition == None or content_disposition == "inline"): + body['plain'].append(content) + elif content_type == "text/html" and (content_disposition == None or content_disposition == "inline"): body['html'].append(content) elif content_disposition: attachment = parse_attachment(part)