1
0
mirror of https://github.com/alanorth/hugo-theme-bootstrap4-blog.git synced 2024-06-26 16:13:45 +02:00

layouts/_default/baseof.html: Use .Site.RegularPages instead of .Site.Pages

Hugo 0.18 changes the pages returned by .Site.Pages, so we need to
use .Site.RegularPages in order to test the type.

See: https://github.com/spf13/hugo/releases/tag/v0.18
See: https://gohugo.io/templates/variables#site-variables
This commit is contained in:
Alan Orth 2016-12-25 17:56:24 +02:00
parent 08a93fc71e
commit 8616dd8c10
Signed by: alanorth
GPG Key ID: 0FB860CC9C45B1B9

View File

@ -38,7 +38,7 @@
<a class="nav-link" href="{{.URL | absURL }}">{{ .Name }}</a>
{{ end }}
{{ else }}
{{ range where .Site.Pages "Type" "!=" "post" }}
{{ range where .Site.RegularPages "Type" "!=" "post" }}
<a class="nav-link" href="{{ .Permalink }}">{{ .Title }}</a>
{{ end }}
{{ end }}