X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;ds=sidebyside;f=lib%2Fpleroma%2Fweb%2Frouter.ex;h=2c94d071fb0dd29c93b4c01fac3ba7e60279458d;hb=6cf7c132282e612514af992c6dea0b03ee5b678d;hp=a4f13c879b6746eea9accef186c95bffcde96f62;hpb=1c00eb4a90cddb7518a823d9304f6aee4fd3ef78;p=akkoma diff --git a/lib/pleroma/web/router.ex b/lib/pleroma/web/router.ex index a4f13c879..2c94d071f 100644 --- a/lib/pleroma/web/router.ex +++ b/lib/pleroma/web/router.ex @@ -1,7 +1,7 @@ defmodule Pleroma.Web.Router do use Pleroma.Web, :router - alias Pleroma.{Repo, User} + alias Pleroma.{Repo, User, Web.Router} def user_fetcher(username) do {:ok, Repo.get_by(User, %{nickname: username})} @@ -10,13 +10,13 @@ defmodule Pleroma.Web.Router do pipeline :api do plug :accepts, ["json"] plug :fetch_session - plug Pleroma.Plugs.AuthenticationPlug, %{fetcher: &Pleroma.Web.Router.user_fetcher/1, optional: true} + plug Pleroma.Plugs.AuthenticationPlug, %{fetcher: &Router.user_fetcher/1, optional: true} end pipeline :authenticated_api do plug :accepts, ["json"] plug :fetch_session - plug Pleroma.Plugs.AuthenticationPlug, %{fetcher: &Pleroma.Web.Router.user_fetcher/1} + plug Pleroma.Plugs.AuthenticationPlug, %{fetcher: &Router.user_fetcher/1} end pipeline :well_known do