markdown: clean up html generated by earmark

This commit is contained in:
Ariadne Conill 2019-07-29 19:09:58 +00:00
commit 5795a890e9
2 changed files with 8 additions and 5 deletions

View file

@ -300,6 +300,9 @@ defmodule Pleroma.Web.CommonAPI.Utils do
|> Earmark.as_html!()
|> Formatter.linkify(options)
|> Formatter.html_escape("text/html")
|> (fn {text, mentions, tags} ->
{String.replace(text, ~r/\r?\n/, ""), mentions, tags}
end).()
end
def make_note_data(