blob: 8172c896e76ba91119470f837a36ebf2a0b2b41f (
plain)
1
2
3
4
5
6
7
8
9
|
module ProtectedBranches
class DestroyService < BaseService
def execute(protected_branch)
raise Gitlab::Access::AccessDeniedError unless can?(current_user, :destroy_protected_branch, protected_branch)
protected_branch.destroy
end
end
end
|