diff options
author | Dimitrie Hoekstra <dimitrie@gitlab.com> | 2017-03-17 17:04:51 +0000 |
---|---|---|
committer | Dimitrie Hoekstra <dimitrie@gitlab.com> | 2017-03-17 17:04:51 +0000 |
commit | b6bab6ce47813c67ea1e2c7d4fde7d9e320da99c (patch) | |
tree | 6c1b7db2aeebc5756c73842cffef22df655cc820 /lib/ci/api/runners.rb | |
parent | 116efdaf128ddcccc30fb82615cd964b35cacc53 (diff) | |
parent | bb1620aaf712c22c61fda098260f481ad79a05e2 (diff) | |
download | gitlab-ce-focus-mode-board.tar.gz |
Merge branch 'master' into 'focus-mode-board'focus-mode-board
# Conflicts:
# app/views/shared/issuable/_filter.html.haml
Diffstat (limited to 'lib/ci/api/runners.rb')
-rw-r--r-- | lib/ci/api/runners.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/ci/api/runners.rb b/lib/ci/api/runners.rb index c1fd959ef14..45aa2adccf5 100644 --- a/lib/ci/api/runners.rb +++ b/lib/ci/api/runners.rb @@ -24,13 +24,13 @@ module Ci optional :locked, type: Boolean, desc: 'Lock this runner for this specific project' end post "register" do - runner_params = declared(params, include_missing: false) + runner_params = declared(params, include_missing: false).except(:token) runner = if runner_registration_token_valid? # Create shared runner. Requires admin access Ci::Runner.create(runner_params.merge(is_shared: true)) - elsif project = Project.find_by(runners_token: runner_params[:token]) + elsif project = Project.find_by(runners_token: params[:token]) # Create a specific runner for project. project.runners.create(runner_params) end |