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:
authorStan Hu <stanhu@gmail.com>2015-10-16 10:25:19 +0300
committerStan Hu <stanhu@gmail.com>2015-10-16 10:33:58 +0300
commit888c1a3fc53ff0318cd69d0e7f1edad25f306713 (patch)
tree08229c0a3ab225a9a13ae8e1e75d1f180727191f /app/services
parentbf290a52b7589ccd0e37a224ec36cec28acfb6a8 (diff)
Add spec for refresh service adding notes to restored branches
Diffstat (limited to 'app/services')
-rw-r--r--app/services/merge_requests/refresh_service.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/app/services/merge_requests/refresh_service.rb b/app/services/merge_requests/refresh_service.rb
index c378f14c265..121f6899011 100644
--- a/app/services/merge_requests/refresh_service.rb
+++ b/app/services/merge_requests/refresh_service.rb
@@ -90,9 +90,8 @@ module MergeRequests
# Since any number of commits could have been made to the restored branch,
# find the common root to see what has been added.
common_ref = @project.repository.merge_base(last_commit.id, @newrev)
- # If the last_commit no longer exists in this new branch,
- # gitlab_git throws a Rugged::OdbError
- # This is fixed in https://gitlab.com/gitlab-org/gitlab_git/merge_requests/52
+ # If the a commit no longer exists in this repo, gitlab_git throws
+ # a Rugged::OdbError. This is fixed in https://gitlab.com/gitlab-org/gitlab_git/merge_requests/52
@commits = @project.repository.commits_between(common_ref, @newrev) if common_ref
rescue
end