Skip to content

Commit e06a576

Browse files
committed
do not append ".." unnecessarily
1 parent 4bdfbaa commit e06a576

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

opengrok-web/src/main/java/org/opengrok/web/DiffData.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ public String getRev(int index) {
9696
* @return shortened revision string (maximum 8 characters) with ".." appended
9797
*/
9898
public String getShortRev(int index) {
99-
return rev[index].substring(0, Integer.min(rev[index].length(), 8)) + "..";
99+
return rev[index].substring(0, Integer.min(rev[index].length(), 8)) + (rev[index].length() > 8 ? ".." : "");
100100
}
101101

102102
public String[] getFile(int index) {

0 commit comments

Comments
 (0)