UserIsAdminPlug module name

This commit is contained in:
Alexander Strizhakov 2020-06-24 08:59:35 +03:00
parent 2125286e90
commit 1d16cd0c3d
No known key found for this signature in database
GPG key ID: 022896A53AEF1381
3 changed files with 3 additions and 3 deletions

View file

@ -2,7 +2,7 @@
# Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/> # Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only # SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Plugs.UserIsAdminPlug do defmodule Pleroma.Web.Plugs.UserIsAdminPlug do
import Pleroma.Web.TranslationHelpers import Pleroma.Web.TranslationHelpers
import Plug.Conn import Plug.Conn

View file

@ -67,7 +67,7 @@ defmodule Pleroma.Web.Router do
plug(Pleroma.Plugs.AdminSecretAuthenticationPlug) plug(Pleroma.Plugs.AdminSecretAuthenticationPlug)
plug(:after_auth) plug(:after_auth)
plug(Pleroma.Plugs.EnsureAuthenticatedPlug) plug(Pleroma.Plugs.EnsureAuthenticatedPlug)
plug(Pleroma.Plugs.UserIsAdminPlug) plug(Pleroma.Web.Plugs.UserIsAdminPlug)
plug(Pleroma.Plugs.IdempotencyPlug) plug(Pleroma.Plugs.IdempotencyPlug)
end end

View file

@ -5,7 +5,7 @@
defmodule Pleroma.Web.Plugs.UserIsAdminPlugTest do defmodule Pleroma.Web.Plugs.UserIsAdminPlugTest do
use Pleroma.Web.ConnCase, async: true use Pleroma.Web.ConnCase, async: true
alias Pleroma.Plugs.UserIsAdminPlug alias Pleroma.Web.Plugs.UserIsAdminPlug
import Pleroma.Factory import Pleroma.Factory
test "accepts a user that is an admin" do test "accepts a user that is an admin" do