summaryrefslogtreecommitdiff
path: root/app/services/projects/group_links/create_service.rb
blob: 3562457702454f2b7e752de61f20d1e83a124d95 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
module Projects
  module GroupLinks
    class CreateService < BaseService
      def execute(group)
        return false unless group

        project.project_group_links.create(
          group: group,
          group_access: params[:link_group_access],
          expires_at: params[:expires_at]
        )
      end
    end
  end
end