CommonAPI post: kill \r with fire
authorWilliam Pitcock <nenolod@dereferenced.org>
Wed, 18 Apr 2018 20:30:59 +0000 (20:30 +0000)
committerWilliam Pitcock <nenolod@dereferenced.org>
Wed, 18 Apr 2018 20:46:39 +0000 (15:46 -0500)
lib/pleroma/web/common_api/utils.ex

index 49c4ee1eb6f566a55ca92735d9d9367aea71d8e4..3c092d524101867e916c4734266caa22c9f820fc 100644 (file)
@@ -61,6 +61,7 @@ defmodule Pleroma.Web.CommonAPI.Utils do
 
   def make_content_html(status, mentions, attachments, tags, no_attachment_links \\ false) do
     status
+    |> String.replace("\r", "")
     |> format_input(mentions, tags)
     |> maybe_add_attachments(attachments, no_attachment_links)
   end