summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorOswaldo Ferreira <oswaldo@gitlab.com>2018-03-07 22:29:12 -0300
committerOswaldo Ferreira <oswaldo@gitlab.com>2018-03-07 22:46:29 -0300
commitc6273ec50c019a115b11a8ef1032a64710f0a46a (patch)
treece1a808bafc98f2181a621b75e293c4c27d1899e /lib
parent7734e85bc6592c5ad3330c611c5f83a051b680b0 (diff)
downloadgitlab-ce-c6273ec50c019a115b11a8ef1032a64710f0a46a.tar.gz
Avoid re-fetching merge-base SHA from Gitaly unnecessarily
Diffstat (limited to 'lib')
-rw-r--r--lib/gitlab/diff/diff_refs.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/gitlab/diff/diff_refs.rb b/lib/gitlab/diff/diff_refs.rb
index 88e0db830f6..81df47964be 100644
--- a/lib/gitlab/diff/diff_refs.rb
+++ b/lib/gitlab/diff/diff_refs.rb
@@ -44,7 +44,11 @@ module Gitlab
project.commit(head_sha)
else
straight = start_sha == base_sha
- CompareService.new(project, head_sha).execute(project, start_sha, straight: straight)
+
+ CompareService.new(project, head_sha).execute(project,
+ start_sha,
+ base_sha: base_sha,
+ straight: straight)
end
end
end