Plain text only extended reply header

pull/200/head
M66B 3 years ago
parent fda5e0da5f
commit f345fb8e0c

@ -416,13 +416,12 @@ public class EntityMessage implements Serializable {
} else } else
p.text(DF.format(new Date(received)) + " " + MessageHelper.formatAddresses(from) + ":"); p.text(DF.format(new Date(received)) + " " + MessageHelper.formatAddresses(from) + ":");
if (separate) { Element div = document.createElement("div")
Element div = document.createElement("div"); .attr("fairemail", "reply");
if (separate)
div.appendElement("hr"); div.appendElement("hr");
div.appendChild(p); div.appendChild(p);
return div; return div;
} else
return p;
} }
String getNotificationChannelId() { String getNotificationChannelId() {

@ -41,6 +41,7 @@ import com.sun.mail.util.MessageRemovedIOException;
import org.jsoup.nodes.Document; import org.jsoup.nodes.Document;
import org.jsoup.nodes.Element; import org.jsoup.nodes.Element;
import org.jsoup.select.Elements;
import java.io.BufferedInputStream; import java.io.BufferedInputStream;
import java.io.BufferedOutputStream; import java.io.BufferedOutputStream;
@ -698,6 +699,11 @@ public class MessageHelper {
document.select("div[fairemail=signature]").removeAttr("fairemail"); document.select("div[fairemail=signature]").removeAttr("fairemail");
document.select("div[fairemail=reference]").removeAttr("fairemail"); document.select("div[fairemail=reference]").removeAttr("fairemail");
Elements reply = document.select("div[fairemail=reply]");
if (message.plain_only != null && message.plain_only)
reply.select("strong").tagName("span");
reply.removeAttr("fairemail");
DB db = DB.getInstance(context); DB db = DB.getInstance(context);
try { try {
db.beginTransaction(); db.beginTransaction();

Loading…
Cancel
Save