From f3a9d8bdbe5e2bfcf23ede30c8ebdb112ce49ba9 Mon Sep 17 00:00:00 2001
From: James Moger <james.moger@gitblit.com>
Date: Wed, 26 Jun 2013 16:55:25 -0400
Subject: [PATCH] Fixed AngularJS binding bug on dashboards with commit messages using {{notation}}
---
src/main/java/com/gitblit/models/RefLogEntry.java | 19 ++++++++++++++++++-
1 files changed, 18 insertions(+), 1 deletions(-)
diff --git a/src/main/java/com/gitblit/models/RefLogEntry.java b/src/main/java/com/gitblit/models/RefLogEntry.java
index 54d1777..79e8a2c 100644
--- a/src/main/java/com/gitblit/models/RefLogEntry.java
+++ b/src/main/java/com/gitblit/models/RefLogEntry.java
@@ -160,7 +160,24 @@
}
return null;
}
-
+
+ /**
+ * Adds a commit to the push entry object as long as the commit is not a
+ * duplicate.
+ *
+ * @param branch
+ * @param commit
+ * @return a RepositoryCommit, if one was added. Null if this is duplicate
+ * commit
+ */
+ public RepositoryCommit addCommit(RepositoryCommit commit) {
+ if (commits.add(commit)) {
+ authorCount = -1;
+ return commit;
+ }
+ return null;
+ }
+
/**
* Adds a a list of repository commits. This is used to construct discrete
* ref push log entries
--
Gitblit v1.9.1