diff options
author | Damien Caliste <dcaliste@free.fr> | 2018-09-14 13:35:10 +0200 |
---|---|---|
committer | Pekka Vuorela <pvuorela@iki.fi> | 2018-09-29 11:50:56 +0000 |
commit | cb5c76944c0c3a8ee6360564369c1a3cc409255e (patch) | |
tree | 745c5bf5c12528fa9d95f4d767a6d56975d985f7 /src/libraries/qmfclient/qmailmessage.cpp | |
parent | d761a52dd051c10e59716c27e5dd2ce3eb32f7b2 (diff) |
Add tests for attachment finder
Add two tests to check that attachment finder is working for level 1
and level 2 attachment locations. It's a follow up of previous commit
"Add recursion when looking for attachments". It also check that
calendar invitation is not returned as an attachment.
Change-Id: If84bc67687d50720ab1bc0458e7b57ed21650348
Reviewed-by: Pekka Vuorela <pvuorela@iki.fi>
Reviewed-by: Matthew Vogt <matthew.vogt@qinetic.com.au>
Diffstat (limited to 'src/libraries/qmfclient/qmailmessage.cpp')
-rw-r--r-- | src/libraries/qmfclient/qmailmessage.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/libraries/qmfclient/qmailmessage.cpp b/src/libraries/qmfclient/qmailmessage.cpp index dc782b9e..a04abc67 100644 --- a/src/libraries/qmfclient/qmailmessage.cpp +++ b/src/libraries/qmfclient/qmailmessage.cpp @@ -1163,8 +1163,7 @@ namespace findAttachments bool isText = (contentType.matches("text", "plain") || contentType.matches("text", "html")); - bool isCalendar = (contentType.type().toLower() == "text") && - (contentType.subType().toLower() == "calendar"); + bool isCalendar = contentType.matches("text", "calendar"); bool isInLine = (!part.contentDisposition().isNull()) && (part.contentDisposition().type() == QMailMessageContentDisposition::Inline); |