summaryrefslogtreecommitdiffstats
path: root/templates/repo/wiki/view.tmpl
diff options
context:
space:
mode:
Diffstat (limited to 'templates/repo/wiki/view.tmpl')
-rw-r--r--templates/repo/wiki/view.tmpl4
1 files changed, 2 insertions, 2 deletions
diff --git a/templates/repo/wiki/view.tmpl b/templates/repo/wiki/view.tmpl
index 15553cedd8..1aa21b906a 100644
--- a/templates/repo/wiki/view.tmpl
+++ b/templates/repo/wiki/view.tmpl
@@ -80,8 +80,8 @@
</summary>
{{$level := 0}}
{{range .toc}}
- {{if lt $level .Level}}{{range Iterate (Subtract .Level $level)}}<ul>{{end}}{{end}}
- {{if gt $level .Level}}{{range Iterate (Subtract $level .Level)}}</ul>{{end}}{{end}}
+ {{if lt $level .Level}}{{range Iterate (Eval .Level "-" $level)}}<ul>{{end}}{{end}}
+ {{if gt $level .Level}}{{range Iterate (Eval $level "-" .Level)}}</ul>{{end}}{{end}}
{{$level = .Level}}
<li><a href="#{{.ID}}">{{.Text}}</a></li>
{{end}}