Check for attachments in the body only

pull/168/head
M66B 5 years ago
parent f2fa4800d7
commit d30cbb31ab

@ -3083,9 +3083,12 @@ public class FragmentCompose extends FragmentBase {
}
}
String plain = HtmlHelper.getText(body);
Document d = JsoupEx.parse(body);
d.select("div[fairemail=signature]").remove();
d.select("div[fairemail=reference]").remove();
String text = d.text();
for (String keyword : keywords)
if (plain.matches("(?si).*\\b" + Pattern.quote(keyword.trim()) + "\\b.*")) {
if (text.matches("(?si).*\\b" + Pattern.quote(keyword.trim()) + "\\b.*")) {
args.putBoolean("remind_attachment", true);
break;
}

Loading…
Cancel
Save