diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-01-28 17:00:40 -0800 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-01-28 17:00:40 -0800 |
commit | 953c1fff8f242f09f3f16998112931d48d6a5ecc (patch) | |
tree | 3ecbdda1fa2ba497a306370071dee3e713df413e /lib | |
parent | 1718075a02a0774029f3739be5b0717bc9224a04 (diff) | |
download | gitlab-ce-953c1fff8f242f09f3f16998112931d48d6a5ecc.tar.gz |
Be more careful with parsing changes from gitlab-shell
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/git_access.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/git_access.rb b/lib/gitlab/git_access.rb index c7bf2efc628..ea96d04c5ab 100644 --- a/lib/gitlab/git_access.rb +++ b/lib/gitlab/git_access.rb @@ -73,7 +73,7 @@ module Gitlab changes = changes.lines if changes.kind_of?(String) # Iterate over all changes to find if user allowed all of them to be applied - changes.each do |change| + changes.map(&:strip).reject(&:blank?).each do |change| status = change_access_check(user, project, change) unless status.allowed? # If user does not have access to make at least one change - cancel all push |