From: Jeremy Schlatter Date: Wed, 3 Dec 2014 00:08:29 +0000 (-0800) Subject: Label broken MIME attachments as ContentType: application/octet-stream rather than... X-Git-Tag: v0.3.24^2~1 X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=254942e602efc39ab99d4f11448b52d3bc5d7810;p=flanker.git Label broken MIME attachments as ContentType: application/octet-stream rather than ContentType: text/plain --- diff --git a/flanker/mime/create.py b/flanker/mime/create.py index 816826d..7b8cefa 100644 --- a/flanker/mime/create.py +++ b/flanker/mime/create.py @@ -69,7 +69,7 @@ def attachment(content_type, body, filename=None, message.headers['Content-Disposition'] = WithParams(disposition) return message except DecodingError: - content_type = ContentType('text', 'plain') + content_type = ContentType('application', 'octet-stream') return binary( content_type.main, content_type.sub,