Skip to content

Commit 0ea17fc

Browse files
committed
Merge pull request #3 from docbobo/master
ActivityPage causes IndexOutOfBoundsException
2 parents ff148dd + 99721ac commit 0ea17fc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/com/gitblit/utils/ActivityUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public static List<Activity> getRecentActivity(List<RepositoryModel> models, int
8585

8686
// determine commit branch
8787
String branch = objectId;
88-
if (StringUtils.isEmpty(branch)) {
88+
if (StringUtils.isEmpty(branch) && !commits.isEmpty()) {
8989
List<RefModel> headRefs = allRefs.get(commits.get(0).getId());
9090
List<String> localBranches = new ArrayList<String>();
9191
for (RefModel ref : headRefs) {

0 commit comments

Comments
 (0)