diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-03-31 16:31:53 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-03-31 16:31:53 +0300 |
commit | 9b276f0003d19599e6426eb5f58028a81ede4a30 (patch) | |
tree | a67e60f1d871189e309516bdd86b4a8d5273f733 /lib/api/commits.rb | |
parent | 2ab2d60b9ea42f5631bfd4cd48b16a02d065215e (diff) | |
download | gitlab-ce-9b276f0003d19599e6426eb5f58028a81ede4a30.tar.gz |
Move branches api to separate class
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'lib/api/commits.rb')
-rw-r--r-- | lib/api/commits.rb | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/lib/api/commits.rb b/lib/api/commits.rb index 33b8b3d2244..4a67313430a 100644 --- a/lib/api/commits.rb +++ b/lib/api/commits.rb @@ -1,21 +1,12 @@ require 'mime/types' module API - # Projects API + # Projects commits API class Commits < Grape::API before { authenticate! } before { authorize! :download_code, user_project } resource :projects do - helpers do - def handle_project_member_errors(errors) - if errors[:project_access].any? - error!(errors[:project_access], 422) - end - not_found! - end - end - # Get a project repository commits # # Parameters: |