diff options
Diffstat (limited to 'app/services/ci/create_project_service.rb')
-rw-r--r-- | app/services/ci/create_project_service.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/app/services/ci/create_project_service.rb b/app/services/ci/create_project_service.rb index 0419612d521..839d3f6b444 100644 --- a/app/services/ci/create_project_service.rb +++ b/app/services/ci/create_project_service.rb @@ -2,20 +2,15 @@ module Ci class CreateProjectService include Gitlab::Application.routes.url_helpers - def execute(current_user, params, project_route, forked_project = nil) + def execute(current_user, params, forked_project = nil) @project = Ci::Project.parse(params) Ci::Project.transaction do @project.save! - data = { - token: @project.token, - project_url: project_route.gsub(":project_id", @project.id.to_s), - } - gl_project = ::Project.find(@project.gitlab_id) gl_project.build_missing_services - gl_project.gitlab_ci_service.update_attributes(data.merge(active: true)) + gl_project.gitlab_ci_service.update_attributes(active: true, token: @project.token) end if forked_project |