Skip to content

Commit

Permalink
Update MarkupUtil.java
Browse files Browse the repository at this point in the history
  • Loading branch information
xdnw committed Aug 5, 2024
1 parent 08a98d9 commit d917841
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/main/java/link/locutus/discord/util/MarkupUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,7 @@ public static String transformURLIntoMarkup(String text){
private static final HtmlRenderer MARKDOWN_RENDERER;
static {
MARKDOWN_TO_HTML.set(Parser.EXTENSIONS, Arrays.asList(StrikethroughExtension.create()));
MARKDOWN_TO_HTML.set(HtmlRenderer.SOFT_BREAK, "<br />");
MARKDOWN_PARSER = Parser.builder(MARKDOWN_TO_HTML).build();
MARKDOWN_RENDERER = HtmlRenderer.builder(MARKDOWN_TO_HTML).build();
}
Expand All @@ -341,6 +342,7 @@ public static String markdownToHTML(String source) {
}
html = transformURLIntoLinks(html);
}
System.out.println("HTML " + html);
return html.replaceAll("\n", "");
//
// source = source.replace("_", "\u200B\t").replace(" * ", "\u200B\r");
Expand Down

0 comments on commit d917841

Please sign in to comment.