summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMarin Jankovski <maxlazio@gmail.com>2013-10-04 12:38:49 +0200
committerMarin Jankovski <maxlazio@gmail.com>2013-10-04 12:38:49 +0200
commitfa7d75733cf8c861fd6ad479b0397877f5a08332 (patch)
tree81b9461fd7d577b2f1940954aff26498aa296b50 /lib
parent970d86b7c5d0be871d8ab8d7cbd51997fd62e28a (diff)
downloadgitlab-ce-fa7d75733cf8c861fd6ad479b0397877f5a08332.tar.gz
Fix failed merge when filename is the same as target branchname.
Diffstat (limited to 'lib')
-rw-r--r--lib/gitlab/satellite/merge_action.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/satellite/merge_action.rb b/lib/gitlab/satellite/merge_action.rb
index 156483be8dd..5d56852f058 100644
--- a/lib/gitlab/satellite/merge_action.rb
+++ b/lib/gitlab/satellite/merge_action.rb
@@ -149,7 +149,7 @@ module Gitlab
# We can't trust the input here being branch names, we can't always check it out because it could be a relative ref i.e. HEAD~3
# we could actually remove the if true, because it should never ever happen (as long as the satellite has been prepared)
repo.git.checkout(default_options, "#{merge_request.source_branch}")
- repo.git.checkout(default_options, "#{merge_request.target_branch}")
+ repo.git.checkout(default_options({t: true}), "origin/#{merge_request.target_branch}")
end
rescue Grit::Git::CommandFailed => ex
handle_exception(ex)