0
0
Fork 0

Add admin API for managing canonical e-mail blocks (#19067)

This commit is contained in:
Eugen Rochko 2022-08-28 03:31:54 +02:00 committed by GitHub
parent b399d79545
commit c556c3a0d1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 177 additions and 36 deletions

View file

@ -0,0 +1,23 @@
# frozen_string_literal: true
class CanonicalEmailBlockPolicy < ApplicationPolicy
def index?
role.can?(:manage_blocks)
end
def show?
role.can?(:manage_blocks)
end
def test?
role.can?(:manage_blocks)
end
def create?
role.can?(:manage_blocks)
end
def destroy?
role.can?(:manage_blocks)
end
end