From f437eb06e1be54ad1c1c338fcef2548eba3b3a8f Mon Sep 17 00:00:00 2001 From: M66B Date: Sat, 7 Nov 2020 18:39:24 +0100 Subject: [PATCH] Oops --- app/src/main/java/eu/faircode/email/HtmlHelper.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/HtmlHelper.java b/app/src/main/java/eu/faircode/email/HtmlHelper.java index 50c6131688..79b870444a 100644 --- a/app/src/main/java/eu/faircode/email/HtmlHelper.java +++ b/app/src/main/java/eu/faircode/email/HtmlHelper.java @@ -2091,12 +2091,12 @@ public class HtmlHelper { element = (Element) node; if ("true".equals(element.attr("x-block"))) - if (ssb.length() > 1 && ssb.charAt(ssb.length() - 1) != '\n') + if (ssb.length() > 0 && ssb.charAt(ssb.length() - 1) != '\n') ssb.append('\n'); if ("true".equals(element.attr("x-paragraph")) && !"false".equals(element.attr("x-line-before"))) - if (ssb.length() > 2 && + if (ssb.length() > 1 && (ssb.charAt(ssb.length() - 2) != '\n' || ssb.charAt(ssb.length() - 1) != '\n')) ssb.append('\n'); @@ -2355,12 +2355,12 @@ public class HtmlHelper { } if ("true".equals(element.attr("x-block"))) - if (ssb.length() > 1 && ssb.charAt(ssb.length() - 1) != '\n') + if (ssb.length() > 0 && ssb.charAt(ssb.length() - 1) != '\n') ssb.append('\n'); if ("true".equals(element.attr("x-paragraph")) && !"false".equals(element.attr("x-line-after"))) - if (ssb.length() > 2 && + if (ssb.length() > 1 && (ssb.charAt(ssb.length() - 2) != '\n' || ssb.charAt(ssb.length() - 1) != '\n')) ssb.append('\n');