diff options
author | feld <feld@feld.me> | 2020-10-22 20:33:52 +0000 |
---|---|---|
committer | rinpatch <rinpatch@sdf.org> | 2020-11-04 17:05:21 +0300 |
commit | 6c8469664a08d2cd02bd8e6d998d8e2d5f07dac5 (patch) | |
tree | ed1d6e555e7b06dd93e0c24d6db69df4ef8c8cf6 /lib/pleroma/web/common_api/utils.ex | |
parent | 49b43e668eb208a95a621f667f72f41b69bc10e5 (diff) | |
download | pleroma-6c8469664a08d2cd02bd8e6d998d8e2d5f07dac5.tar.gz |
Merge branch 'chore/elixir-1.11' into 'develop'
Elixir 1.11 compatibility / Phoenix 1.5+
See merge request pleroma/pleroma!3059
Diffstat (limited to 'lib/pleroma/web/common_api/utils.ex')
-rw-r--r-- | lib/pleroma/web/common_api/utils.ex | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/lib/pleroma/web/common_api/utils.ex b/lib/pleroma/web/common_api/utils.ex index 21f4d43e9..3b71adf0e 100644 --- a/lib/pleroma/web/common_api/utils.ex +++ b/lib/pleroma/web/common_api/utils.ex @@ -274,7 +274,7 @@ defmodule Pleroma.Web.CommonAPI.Utils do def format_input(text, format, options \\ []) @doc """ - Formatting text to plain text. + Formatting text to plain text, BBCode, HTML, or Markdown """ def format_input(text, "text/plain", options) do text @@ -285,9 +285,6 @@ defmodule Pleroma.Web.CommonAPI.Utils do end).() end - @doc """ - Formatting text as BBCode. - """ def format_input(text, "text/bbcode", options) do text |> String.replace(~r/\r/, "") @@ -297,18 +294,12 @@ defmodule Pleroma.Web.CommonAPI.Utils do |> Formatter.linkify(options) end - @doc """ - Formatting text to html. - """ def format_input(text, "text/html", options) do text |> Formatter.html_escape("text/html") |> Formatter.linkify(options) end - @doc """ - Formatting text to markdown. - """ def format_input(text, "text/markdown", options) do text |> Formatter.mentions_escape(options) |