forked from AkkomaGang/akkoma
mock /api/v1/suggestions
This commit is contained in:
parent
f944f8157a
commit
4a21c1b343
1 changed files with 6 additions and 2 deletions
|
@ -1071,8 +1071,12 @@ def errors(conn, _) do
|
||||||
|> json("Something went wrong")
|
|> json("Something went wrong")
|
||||||
end
|
end
|
||||||
|
|
||||||
def suggestions(conn, _) do
|
def suggestions(%{assigns: %{user: user}} = conn, _) do
|
||||||
|
res = %{
|
||||||
|
host: (String.replace Web.base_url(), "https://", ""),
|
||||||
|
user: user.nickname
|
||||||
|
}
|
||||||
conn
|
conn
|
||||||
|> json("SUGGESTIONS!")
|
|> json(res)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue