aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java
diff options
context:
space:
mode:
authorMatthias Sohn <matthias.sohn@sap.com>2018-04-25 01:44:43 +0200
committerMatthias Sohn <matthias.sohn@sap.com>2018-04-25 03:28:51 +0200
commit9edf9bf2d6fd248daf2157bc8245142e5d51f7c2 (patch)
treebde5d20cc6858d47587afd8594ddf8c77675dde1 /org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java
parentf26d6558f865cb6a64d0996c534a858310e8b9bb (diff)
downloadjgit-9edf9bf2d6fd248daf2157bc8245142e5d51f7c2.tar.gz
jgit-9edf9bf2d6fd248daf2157bc8245142e5d51f7c2.zip
Remove trivial cases of using deprecated RefDatabase.getRefs()
Change-Id: I2d3e426a3391923f8a690ac68fcc33851f3eb419 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java')
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java7
1 files changed, 3 insertions, 4 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java
index 46fd5cf1d6..4061928498 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java
@@ -58,7 +58,6 @@ import java.util.HashSet;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
-import java.util.Map;
import java.util.Set;
import org.eclipse.jgit.errors.CompoundException;
@@ -690,13 +689,13 @@ class WalkFetchConnection extends BaseFetchConnection {
}
private void markLocalRefsComplete(final Set<ObjectId> have) throws TransportException {
- Map<String, Ref> refs;
+ List<Ref> refs;
try {
- refs = local.getRefDatabase().getRefs(ALL);
+ refs = local.getRefDatabase().getRefsByPrefix(ALL);
} catch (IOException e) {
throw new TransportException(e.getMessage(), e);
}
- for (final Ref r : refs.values()) {
+ for (final Ref r : refs) {
try {
markLocalObjComplete(revWalk.parseAny(r.getObjectId()));
} catch (IOException readError) {