aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorHaelwenn (lanodan) Monnier <contact@hacktivis.me>2018-10-25 06:05:13 +0200
committerHaelwenn (lanodan) Monnier <contact@hacktivis.me>2018-10-25 06:21:11 +0200
commitb386888a0e8b13883f1457c2c62db8bd8b6744ce (patch)
tree2bb63f34483cebb395d6270b0a68860795e99add /lib
parentb112112c1100243aa58721fd2efb756ad119c506 (diff)
downloadpleroma-b386888a0e8b13883f1457c2c62db8bd8b6744ce.tar.gz
[Pleroma.Web.MastodonAPI.MastodonAPIController]: fallback for try_render/4
Better be sure than sorry
Diffstat (limited to 'lib')
-rw-r--r--lib/pleroma/web/mastodon_api/mastodon_api_controller.ex6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex b/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
index 77146d780..751698ca8 100644
--- a/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
+++ b/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
@@ -1215,4 +1215,10 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIController do
res
end
end
+
+ def try_render(conn, _, _, _) do
+ conn
+ |> put_status(501)
+ |> json(%{error: "Can't display this activity"})
+ end
end