"html" ->
conn
|> put_resp_content_type("text/html")
- |> send_file(200, "priv/static/index.html")
+ |> send_file(200, Pleroma.Plugs.InstanceStatic.file_path("index.html"))
_ ->
represent_activity(conn, format, activity, user)
conn,
"activity+json",
%Activity{data: %{"type" => "Create"}} = activity,
- user
+ _user
) do
object = Object.normalize(activity.data["object"])
|> json(ObjectView.render("object.json", %{object: object}))
end
- defp represent_activity(conn, "activity+json", _, _) do
+ defp represent_activity(_conn, "activity+json", _, _) do
{:error, :not_found}
end