diff options
author | Zeger-Jan van de Weg <git@zjvandeweg.nl> | 2017-12-01 15:32:57 +0100 |
---|---|---|
committer | Zeger-Jan van de Weg <git@zjvandeweg.nl> | 2017-12-01 15:32:57 +0100 |
commit | 020a8482a47de625e2bfaa6f13a12e7cd8fe3600 (patch) | |
tree | 36e35677aa0b6d9b56797fcb93dc465e4fea9e63 | |
parent | 3b6fba728fdef4b1824dcfc33539e696e4f17cf5 (diff) | |
download | gitlab-ce-020a8482a47de625e2bfaa6f13a12e7cd8fe3600.tar.gz |
Use commit finder instead of rev parse
This has the side effect of making this method rugged call free, which
is the reason I actually changed this.
-rw-r--r-- | app/models/repository.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/repository.rb b/app/models/repository.rb index 165dafd83fd..82af299ec5e 100644 --- a/app/models/repository.rb +++ b/app/models/repository.rb @@ -256,7 +256,7 @@ class Repository end def diverging_commit_counts(branch) - root_ref_hash = raw_repository.rev_parse_target(root_ref).oid + root_ref_hash = raw_repository.commit(root_ref).id cache.fetch(:"diverging_commit_counts_#{branch.name}") do # Rugged seems to throw a `ReferenceError` when given branch_names rather # than SHA-1 hashes |