Welcome to mirror list, hosted at ThFree Co, Russian Federation.

create_service.rb « protected_tags « services « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 65303f21a4a38ee62f919d738e5b711be2472bfa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# frozen_string_literal: true

module ProtectedTags
  class CreateService < ::BaseService
    attr_reader :protected_tag

    def execute
      raise Gitlab::Access::AccessDeniedError unless can?(current_user, :admin_project, project)

      project.protected_tags.create(params)
    end
  end
end