mirror of
https://github.com/M66B/FairEmail.git
synced 2025-01-04 06:20:26 +00:00
Fixed extra newlines
This commit is contained in:
parent
926c4b476b
commit
b2e533b05d
1 changed files with 9 additions and 2 deletions
|
@ -755,9 +755,16 @@ public class HtmlHelper {
|
||||||
|
|
||||||
// Paragraphs
|
// Paragraphs
|
||||||
for (Element p : document.select("p")) {
|
for (Element p : document.select("p")) {
|
||||||
if (p.childNodeSize() != 0)
|
|
||||||
p.attr("x-paragraph", "true");
|
|
||||||
p.tagName("div");
|
p.tagName("div");
|
||||||
|
if (p.childNodeSize() != 0) {
|
||||||
|
if (p.childNodeSize() == 1) {
|
||||||
|
Node lonely = p.childNode(0);
|
||||||
|
if (lonely instanceof TextNode &&
|
||||||
|
"\u00a0".equals(((TextNode) lonely).getWholeText()))
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
p.attr("x-paragraph", "true");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Short inline quotes
|
// Short inline quotes
|
||||||
|
|
Loading…
Reference in a new issue