aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/pleroma/web/mastodon_api/mastodon_api_controller.ex8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex b/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
index 0184d52c8..0f50eba84 100644
--- a/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
+++ b/lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
@@ -1071,8 +1071,12 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIController do
|> json("Something went wrong")
end
- def suggestions(conn, _) do
+ def suggestions(%{assigns: %{user: user}} = conn, _) do
+ res = %{
+ host: (String.replace Web.base_url(), "https://", ""),
+ user: user.nickname
+ }
conn
- |> json("SUGGESTIONS!")
+ |> json(res)
end
end