diff options
author | Robert Schilling <rschilling@student.tugraz.at> | 2017-08-31 13:44:49 +0200 |
---|---|---|
committer | Robert Schilling <rschilling@student.tugraz.at> | 2017-08-31 14:57:47 +0200 |
commit | 6a2ee0968e811d31fb4cc23b30a6b42e42adf47b (patch) | |
tree | 0f1a0cd92093b13d63d576c7607e5f4b4e330fdc /lib/api/services.rb | |
parent | a768e1b7048c17d4dde8ee086c7ff7dc2b43762e (diff) | |
download | gitlab-ce-6a2ee0968e811d31fb4cc23b30a6b42e42adf47b.tar.gz |
API: Use defined project requirementsrs-api-use-project-requirements
Diffstat (limited to 'lib/api/services.rb')
-rw-r--r-- | lib/api/services.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/api/services.rb b/lib/api/services.rb index ff9ddd44439..2cbd0517dc3 100644 --- a/lib/api/services.rb +++ b/lib/api/services.rb @@ -601,7 +601,7 @@ module API params do requires :id, type: String, desc: 'The ID of a project' end - resource :projects, requirements: { id: %r{[^/]+} } do + resource :projects, requirements: API::PROJECT_ENDPOINT_REQUIREMENTS do before { authenticate! } before { authorize_admin_project } @@ -691,7 +691,7 @@ module API params do requires :id, type: String, desc: 'The ID of a project' end - resource :projects, requirements: { id: %r{[^/]+} } do + resource :projects, requirements: API::PROJECT_ENDPOINT_REQUIREMENTS do desc "Trigger a slash command for #{service_slug}" do detail 'Added in GitLab 8.13' end |