Body text is not an attachment

This commit is contained in:
M66B 2019-01-10 13:44:31 +00:00
parent b92819222a
commit bf9ce3e9df
1 changed files with 10 additions and 1 deletions

View File

@ -519,7 +519,16 @@ public class MessageHelper {
}
private static String getHtml(Part part) throws MessagingException, IOException {
if (part.isMimeType("text/plain") || part.isMimeType("text/html")) {
String disposition;
try {
disposition = part.getDisposition();
} catch (MessagingException ex) {
Log.w(ex);
disposition = null;
}
if (!Part.ATTACHMENT.equalsIgnoreCase(disposition) &&
(part.isMimeType("text/plain") || part.isMimeType("text/html"))) {
String s;
try {
Object content = part.getContent();