if (end != -1 && (end == n - 1 || !Character.isLetter(text.charAt(end + 1)))) { if (i > flushIndex) { appendEscapedText(sb, text, html, flushIndex, i, escapeUnicode); appendEscapedText(sb, text, html, i + 1, end, escapeUnicode); sb.append('<').append('/').append(tag).append('>'); } else { appendEscapedText(sb, text, html, i + 1, end, escapeUnicode); appendEscapedText(sb, text, html, flushIndex, i, escapeUnicode); appendEscapedText(sb, text, html, flushIndex, n, escapeUnicode);