diff options
| -rw-r--r-- | layouts/_default/list.html | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html index b7dc3ef..4c84589 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -1,12 +1,16 @@ {{ partial "header.html" . }} -{{ if not .IsHome }} +{{ $pctx := . }} + +{{ if .IsHome }} +{{ $pctx = .Site }} +{{ else }} <header class="page-header"> <h1>{{ if eq .Data.Singular "tag" }}{{ .Data.Term }}{{ else }}Posts{{ end }}</h1> </header> {{ end }} -{{ $paginator := .Paginate (where .Site.RegularPages "Type" "in" .Site.Params.mainSections) }} +{{ $paginator := .Paginate (where $pctx.RegularPages "Type" "in" .Site.Params.mainSections) }} {{ if gt $paginator.TotalPages 0 }} {{ range $index, $page := $paginator.Pages }} |
