aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorHaelwenn <contact+git.pleroma.social@hacktivis.me>2019-09-11 17:47:19 +0000
committerHaelwenn <contact+git.pleroma.social@hacktivis.me>2019-09-11 17:47:19 +0000
commit46ae62d159ca0a330d18a2e1f775a5ed9eaebc42 (patch)
tree1b130bbe4ce89840958a43fdcd25126a4cbb1a73 /lib
parentfb7332aec7e5db781ffddf01e1510ffbfc9eac11 (diff)
parente5c6bf3673a8361d1417eba1ccc44edec7658ac4 (diff)
downloadpleroma-46ae62d159ca0a330d18a2e1f775a5ed9eaebc42.tar.gz
Merge branch 'patch-5' into 'develop'
Mastodon API: URI encode hashtag name in generated URLs See merge request pleroma/pleroma!1642
Diffstat (limited to 'lib')
-rw-r--r--lib/pleroma/web/mastodon_api/views/status_view.ex2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pleroma/web/mastodon_api/views/status_view.ex b/lib/pleroma/web/mastodon_api/views/status_view.ex
index b6a3431f9..ef796cddd 100644
--- a/lib/pleroma/web/mastodon_api/views/status_view.ex
+++ b/lib/pleroma/web/mastodon_api/views/status_view.ex
@@ -497,7 +497,7 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do
object_tags = for tag when is_binary(tag) <- object_tags, do: tag
Enum.reduce(object_tags, [], fn tag, tags ->
- tags ++ [%{name: tag, url: "/tag/#{tag}"}]
+ tags ++ [%{name: tag, url: "/tag/#{URI.encode(tag)}"}]
end)
end