Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatricio Cano <suprnova32@gmail.com>2016-06-22 21:03:24 +0300
committerPatricio Cano <suprnova32@gmail.com>2016-07-06 00:54:22 +0300
commit8b14d1d2c20a5b8c7ef985007f90fd3aa12c3277 (patch)
tree8feea6564958e689d056ba5e483a1369c06f51cb /app/services/commits
parent7735ef86f0714a5b2a4cb4db8ec0471654563885 (diff)
Rename ENV['PROTOCOL'] to ENV['GL_PROTOCOL'] to conform to what GitLab Shell expects and make the `protocol` param in `GitAccess` mandatory.
Diffstat (limited to 'app/services/commits')
-rw-r--r--app/services/commits/change_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/commits/change_service.rb b/app/services/commits/change_service.rb
index 6b69cb53b2c..c578097376a 100644
--- a/app/services/commits/change_service.rb
+++ b/app/services/commits/change_service.rb
@@ -23,7 +23,7 @@ module Commits
private
def check_push_permissions
- allowed = ::Gitlab::GitAccess.new(current_user, project).can_push_to_branch?(@target_branch)
+ allowed = ::Gitlab::GitAccess.new(current_user, project, 'web').can_push_to_branch?(@target_branch)
unless allowed
raise ValidationError.new('You are not allowed to push into this branch')