summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2014-03-03 17:23:15 -0500
committerJames Moger <james.moger@gitblit.com>2014-03-03 17:23:15 -0500
commit7717756f44f0b477bc78544ad6762d10f32d03d0 (patch)
tree4255db8c3767a0fe3e3ddca3b3ca8e33404d6aa2 /src
parent1f3dff18737576a30bad8e1b7ea45c00fcad265a (diff)
downloadgitblit-7717756f44f0b477bc78544ad6762d10f32d03d0.tar.gz
gitblit-7717756f44f0b477bc78544ad6762d10f32d03d0.zip
Fixed rounded timestamps of reflogs
Diffstat (limited to 'src')
-rw-r--r--src/main/java/com/gitblit/wicket/panels/DigestsPanel.java7
-rw-r--r--src/main/java/com/gitblit/wicket/panels/ReflogPanel.java4
2 files changed, 2 insertions, 9 deletions
diff --git a/src/main/java/com/gitblit/wicket/panels/DigestsPanel.java b/src/main/java/com/gitblit/wicket/panels/DigestsPanel.java
index 318e74c2..237db04d 100644
--- a/src/main/java/com/gitblit/wicket/panels/DigestsPanel.java
+++ b/src/main/java/com/gitblit/wicket/panels/DigestsPanel.java
@@ -88,13 +88,6 @@ public class DigestsPanel extends BasePanel {
} else if (TimeUtils.isYesterday(pushDate, timezone)) {
fuzzydate = tu.yesterday();
} else {
- // calculate a fuzzy time ago date
- cal.setTime(pushDate);
- cal.set(Calendar.HOUR_OF_DAY, 0);
- cal.set(Calendar.MINUTE, 0);
- cal.set(Calendar.SECOND, 0);
- cal.set(Calendar.MILLISECOND, 0);
- pushDate = cal.getTime();
fuzzydate = getTimeUtils().timeAgo(pushDate);
}
logItem.add(new Label("whenChanged", fuzzydate + ", " + df.format(pushDate)));
diff --git a/src/main/java/com/gitblit/wicket/panels/ReflogPanel.java b/src/main/java/com/gitblit/wicket/panels/ReflogPanel.java
index abd4ecd3..35fd681b 100644
--- a/src/main/java/com/gitblit/wicket/panels/ReflogPanel.java
+++ b/src/main/java/com/gitblit/wicket/panels/ReflogPanel.java
@@ -149,8 +149,8 @@ public class ReflogPanel extends BasePanel {
cal.set(Calendar.MINUTE, 0);
cal.set(Calendar.SECOND, 0);
cal.set(Calendar.MILLISECOND, 0);
- changeDate = cal.getTime();
- fuzzydate = getTimeUtils().timeAgo(changeDate);
+ Date date = cal.getTime();
+ fuzzydate = getTimeUtils().timeAgo(date);
}
changeItem.add(new Label("whenChanged", fuzzydate + ", " + df.format(changeDate)));