end
end
+ def logout(conn, _) do
+ conn
+ |> clear_session
+ |> redirect(to: "/")
+ end
+
def relationship_noop(%{assigns: %{user: user}} = conn, %{"id" => id}) do
Logger.debug("Unimplemented, returning unmodified relationship")
with %User{} = target <- Repo.get(User, id) do
get "/webfinger", WebFinger.WebFingerController, :webfinger
end
- scope "/web", Pleroma.Web.MastodonAPI do
+ scope "/", Pleroma.Web.MastodonAPI do
pipe_through :mastodon_html
- get "/login", MastodonAPIController, :login
- post "/login", MastodonAPIController, :login_post
- get "/*path", MastodonAPIController, :index
+ get "/web/login", MastodonAPIController, :login
+ post "/web/login", MastodonAPIController, :login_post
+ get "/web/*path", MastodonAPIController, :index
+ delete "/auth/sign_out", MastodonAPIController, :logout
end
scope "/", Fallback do