mirror of
https://github.com/M66B/FairEmail.git
synced 2026-01-04 20:03:52 +01:00
Append br to div with one text node
This commit is contained in:
@@ -366,8 +366,9 @@ public class HtmlHelper {
|
||||
// Prevent too many line breaks
|
||||
for (Element div : document.select("div")) {
|
||||
div.tagName("span");
|
||||
if (div.parent() != null)
|
||||
div.after(document.createElement("br"));
|
||||
if (div.childNodeSize() == 1 && div.childNode(0) instanceof TextNode)
|
||||
div.appendElement("br");
|
||||
div.appendElement("br");
|
||||
}
|
||||
|
||||
Element body = document.body();
|
||||
|
||||
Reference in New Issue
Block a user