summaryrefslogtreecommitdiffstats
path: root/src/com
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2012-03-20 19:40:08 -0400
committerJames Moger <james.moger@gitblit.com>2012-03-20 19:40:08 -0400
commit6cbe89ac2b96023bda74c97a61e7e0011db2bb08 (patch)
treee9f4b926722cf12f11301b223ffc67a34645d436 /src/com
parent856091d000befd51967f20e1a7e59ccc59663f99 (diff)
downloadgitblit-6cbe89ac2b96023bda74c97a61e7e0011db2bb08.tar.gz
gitblit-6cbe89ac2b96023bda74c97a61e7e0011db2bb08.zip
Disable default branch/HEAD selector on create/empty repository
Diffstat (limited to 'src/com')
-rw-r--r--src/com/gitblit/wicket/pages/EditRepositoryPage.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/gitblit/wicket/pages/EditRepositoryPage.java b/src/com/gitblit/wicket/pages/EditRepositoryPage.java
index bd84ae3c..5b2124ac 100644
--- a/src/com/gitblit/wicket/pages/EditRepositoryPage.java
+++ b/src/com/gitblit/wicket/pages/EditRepositoryPage.java
@@ -302,7 +302,7 @@ public class EditRepositoryPage extends RootSubPage {
if (!ArrayUtils.isEmpty(repositoryModel.availableRefs)) {
availableRefs.addAll(repositoryModel.availableRefs);
}
- form.add(new DropDownChoice<String>("HEAD", availableRefs).setEnabled(!isCreate));
+ form.add(new DropDownChoice<String>("HEAD", availableRefs).setEnabled(availableRefs.size() > 0));
// federation strategies - remove ORIGIN choice if this repository has
// no origin.