Skip to content

Commit

Permalink
https://github.com/bonfire-networks/bonfire-app/issues/916
Browse files Browse the repository at this point in the history
  • Loading branch information
mayel committed Apr 27, 2024
1 parent b033085 commit 72846f6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/web/masto_compatible_router.ex
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ defmodule Bonfire.API.GraphQL.MastoCompatible.Router do
defmacro include_masto_api do
quote do
scope "/" do
pipe_through(:basic_json)
pipe_through(:load_current_auth)
pipe_through([:basic_json, :load_authorization, :load_current_auth])

# add here to override wrong priority order of routes
get "/api/v1/accounts/verify_credentials",
Expand All @@ -14,6 +13,10 @@ defmodule Bonfire.API.GraphQL.MastoCompatible.Router do

get "/api/v1/accounts/:id", Bonfire.API.MastoCompatible.AccountController, :show

get "/api/v1/instance", Bonfire.API.MastoCompatible.InstanceController, :show

post "/api/v1/apps", Bonfire.API.MastoCompatible.AppController, :create

# require Apical
# Apical.router_from_file(unquote(@api_spec),
# controller: Bonfire.API.MastoCompatible,
Expand Down

0 comments on commit 72846f6

Please sign in to comment.