diff options
author | Hoa V. DINH <dinh.viet.hoa@gmail.com> | 2015-06-21 14:08:03 -0700 |
---|---|---|
committer | Hoa V. DINH <dinh.viet.hoa@gmail.com> | 2015-06-21 14:10:27 -0700 |
commit | f8bfcdd313062baf2690578470e7b9ae2c4438e1 (patch) | |
tree | cb8bcaaf902e935a5ddba127c1024b35137d67f6 /src | |
parent | 6ef4527379c412214299dc431d496487a4251389 (diff) |
improved mime types
Diffstat (limited to 'src')
-rw-r--r-- | src/core/rfc822/MCAttachment.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/core/rfc822/MCAttachment.cpp b/src/core/rfc822/MCAttachment.cpp index 014f8341..cdee201b 100644 --- a/src/core/rfc822/MCAttachment.cpp +++ b/src/core/rfc822/MCAttachment.cpp @@ -112,10 +112,7 @@ String * Attachment::mimeTypeForFilename(String * filename) if (result != NULL) return result; - if (ext->isEqual(MCSTR("jpg"))) { - return MCSTR("image/jpeg"); - } - else if (ext->isEqual(MCSTR("jpeg"))) { + if (ext->isEqual(MCSTR("jpeg")) || ext->isEqual(MCSTR("jpg"))) { return MCSTR("image/jpeg"); } else if (ext->isEqual(MCSTR("png"))) { @@ -130,6 +127,9 @@ String * Attachment::mimeTypeForFilename(String * filename) else if (ext->isEqual(MCSTR("txt"))) { return MCSTR("text/plain"); } + else if (ext->isEqual(MCSTR("tiff")) || ext->isEqual(MCSTR("tif"))) { + return MCSTR("image/tiff"); + } return NULL; } |