aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo/single.tmpl
diff options
context:
space:
mode:
Diffstat (limited to 'templates/repo/single.tmpl')
-rw-r--r--templates/repo/single.tmpl4
1 files changed, 2 insertions, 2 deletions
diff --git a/templates/repo/single.tmpl b/templates/repo/single.tmpl
index ed04be0779..4c9406762c 100644
--- a/templates/repo/single.tmpl
+++ b/templates/repo/single.tmpl
@@ -11,7 +11,7 @@
{{ $n := len .Treenames}}
{{if not .IsFile}}<button class="btn btn-default pull-right hidden"><i class="fa fa-plus-square"></i>Add File</button>{{end}}
<div class="dropdown branch-switch">
- <a href="#" class="btn btn-success dropdown-toggle" data-toggle="dropdown"><i class="fa fa-chain"></i>{{.Branchname}}&nbsp;&nbsp;
+ <a href="#" class="btn btn-success dropdown-toggle" data-toggle="dropdown"><i class="fa fa-chain"></i>{{if .CommitId}}{{SubStr .CommitId 0 10}}{{else}}{{.Branchname}}{{end}}&nbsp;&nbsp;
<b class="caret"></b></a>
<ul class="dropdown-menu">
{{range .Branches}}
@@ -41,4 +41,4 @@
{{end}}
</div>
</div>
-{{template "base/footer" .}} \ No newline at end of file
+{{template "base/footer" .}}