X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=lib%2Fpleroma%2Fweb%2Fcommon_api%2Fcommon_api.ex;h=e0987b1a7d36a2340f839980ad6d12aa43d59648;hb=8e1db6a8352754fd70c51ab8527b71180aa15a5b;hp=173353aa5ac363a646a5d56005cb485d4875cd36;hpb=8bdf18d7c10f0e740b2f5e0fa5063c522b8b3872;p=akkoma diff --git a/lib/pleroma/web/common_api/common_api.ex b/lib/pleroma/web/common_api/common_api.ex index 173353aa5..e0987b1a7 100644 --- a/lib/pleroma/web/common_api/common_api.ex +++ b/lib/pleroma/web/common_api/common_api.ex @@ -54,6 +54,9 @@ defmodule Pleroma.Web.CommonAPI do content |> Formatter.html_escape("text/plain") |> Formatter.linkify() + |> (fn {text, mentions, tags} -> + {String.replace(text, ~r/\r?\n/, "
"), mentions, tags} + end).() text end