aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java
diff options
context:
space:
mode:
authorDavid Pursehouse <david.pursehouse@gmail.com>2018-05-22 11:27:30 +0900
committerDavid Pursehouse <david.pursehouse@gmail.com>2018-05-22 11:49:37 +0900
commitf6c4a492d06e0dd345679bfba3399dabbf778f41 (patch)
treef5a3a1f84d581fcdaae05350f5b1604f54559a4e /org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java
parente701c59a859e8fff46a1bc16aee7771a3a8aea8a (diff)
downloadjgit-f6c4a492d06e0dd345679bfba3399dabbf778f41.tar.gz
jgit-f6c4a492d06e0dd345679bfba3399dabbf778f41.zip
Repository: Deprecate #peel method
Callers should use getRefDatabase().peel(ref) instead since it doesn't swallow the IOException. Adapt all trivial callers to user the alternative. DescribeCommand still uses the deprecated method and is not adapted in this change since it will require more refactoring to add handling of the IOException. Change-Id: I14d4a95a5e0570548753b9fc5c03d024dc3ff832 Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java')
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java
index 1bde49df29..dc1871b729 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java
@@ -322,7 +322,7 @@ public abstract class RefAdvertiser {
String peelPart = ""; //$NON-NLS-1$
if (derefTags) {
if (!ref.isPeeled() && repository != null) {
- ref = repository.peel(ref);
+ ref = repository.getRefDatabase().peel(ref);
}
ObjectId peeledObjectId = ref.getPeeledObjectId();
if (peeledObjectId != null) {
@@ -342,7 +342,7 @@ public abstract class RefAdvertiser {
if (!ref.isPeeled()) {
if (repository == null)
continue;
- ref = repository.peel(ref);
+ ref = repository.getRefDatabase().peel(ref);
}
if (ref.getPeeledObjectId() != null)