Rename is_admin? to admin?.

This commit is contained in:
Brenda Wallace
2019-10-19 10:25:12 +13:00
parent 35c9b70bc9
commit fc07571ee1
2 changed files with 4 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
module Admin
class MembersController < ApplicationController
before_action :is_admin?
before_action :admin?
load_and_authorize_resource
respond_to :html
responders :flash
@@ -34,7 +34,7 @@ module Admin
params[:q]
end
def is_admin?
def admin?
authorize! :manage, :all
end
end

View File

@@ -1,6 +1,6 @@
module Admin
class RolesController < ApplicationController
before_action :is_admin?
before_action :admin?
load_and_authorize_resource
respond_to :html
responders :flash
@@ -36,7 +36,7 @@ module Admin
private
def is_admin?
def admin?
authorize! :manage, :all
end