From 73fba6ef98209406f1cf5f2ee00a9dc384b4a2fc Mon Sep 17 00:00:00 2001
From: James Moger <james.moger@gitblit.com>
Date: Mon, 19 Mar 2012 23:11:11 -0400
Subject: [PATCH] Display fewer content fragments for blobs

---
 src/com/gitblit/wicket/pages/EditRepositoryPage.java |   11 ++---------
 1 files changed, 2 insertions(+), 9 deletions(-)

diff --git a/src/com/gitblit/wicket/pages/EditRepositoryPage.java b/src/com/gitblit/wicket/pages/EditRepositoryPage.java
index 172859f..bd84ae3 100644
--- a/src/com/gitblit/wicket/pages/EditRepositoryPage.java
+++ b/src/com/gitblit/wicket/pages/EditRepositoryPage.java
@@ -39,7 +39,6 @@
 import org.apache.wicket.model.Model;
 import org.apache.wicket.model.util.CollectionModel;
 import org.apache.wicket.model.util.ListModel;
-import org.eclipse.jgit.lib.Constants;
 
 import com.gitblit.Constants.AccessRestrictionType;
 import com.gitblit.Constants.FederationStrategy;
@@ -117,14 +116,8 @@
 				new StringChoiceRenderer(), 8, false);
 
 		// indexed local branches palette
-		List<String> allLocalBranches = new ArrayList<String>();
-		if (!ArrayUtils.isEmpty(repositoryModel.availableRefs)) {
-			for (String ref : repositoryModel.availableRefs) {
-				if (ref.startsWith(Constants.R_HEADS)) {
-					allLocalBranches.add(ref);
-				}
-			}
-		}
+		List<String> allLocalBranches = repositoryModel.getLocalBranches();
+
 		final Palette<String> indexedBranchesPalette = new Palette<String>("indexedBranches", new ListModel<String>(
 				indexedBranches), new CollectionModel<String>(allLocalBranches),
 				new StringChoiceRenderer(), 8, false);

--
Gitblit v1.9.1