From 0d2a7b7737f0d723866ac1fcf7ac82311a13ae3b Mon Sep 17 00:00:00 2001 From: Dan Wang Date: Thu, 14 Jul 2016 18:49:29 -0700 Subject: [PATCH] BatchRefUpdate: Remove unused namesToCheck variable This variable has been populated and never used since it was introduced in commit 5cf53fdacf28d5cabe7ad1ed154fe7f4971225a9 (Speed up clone/fetch with large number of refs, 2013-02-18). Noted by FindBugs: "BatchRefUpdate.java:359, UC_USELESS_OBJECT, Priority: Normal" Change-Id: I7aacb49540aaee4a83db3d38b15633bb6c4773d0 Signed-off-by: Dan Wang --- org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java index c0e1fcbfe..266ca7b06 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java @@ -336,7 +336,6 @@ public class BatchRefUpdate { monitor.beginTask(JGitText.get().updatingReferences, commands.size()); List commands2 = new ArrayList( commands.size()); - List namesToCheck = new ArrayList(commands.size()); // First delete refs. This may free the name space for some of the // updates. for (ReceiveCommand cmd : commands) { @@ -345,7 +344,6 @@ public class BatchRefUpdate { cmd.updateType(walk); switch (cmd.getType()) { case CREATE: - namesToCheck.add(cmd.getRefName()); commands2.add(cmd); break; case UPDATE: