Commit 942b11ab authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge branch 'first-commit' into 'master'

MergeRequest#commits.last is actually first_commit

Using a method would be less confusing.

This was discovered in the process of figuring out https://gitlab.com/gitlab-org/gitlab-ee/issues/260

/cc @DouweM 

See merge request !453
parents 26909fe4 f3a7a3ec
......@@ -611,7 +611,7 @@ class MergeRequest < ActiveRecord::Base
end
def source_sha_parent
source_project.repository.commit(commits.last.sha).parents.first.sha
source_project.repository.commit(first_commit.sha).parents.first.sha
end
def ff_merge_possible?
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment