Text parts shown as attachments: Closes #7300

This commit is contained in:
Robert Schroll 2013-08-06 12:36:27 -07:00 committed by Jim Nelson
parent 54fa83d69c
commit 67c4fa2cf7

View file

@ -686,6 +686,16 @@ public class Geary.RFC822.Message : BaseObject {
return;
}
GMime.ContentType content_type = part.get_content_type();
if (part_disposition == Geary.Attachment.Disposition.INLINE &&
content_type.get_media_type().down() == "text") {
string subtype = content_type.get_media_subtype().down();
if (subtype == "html" || subtype == "plain") {
// These are part of the body.
return;
}
}
if (requested_disposition == null) {
// Return any attachment whose disposition is recognized by Geary.Attachment.Disposition
attachments.add(part);