Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mismith0227/hugo_theme_pickles.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Hsiao <lwhsiao@stanford.edu>2019-11-17 06:17:22 +0300
committerLuke Hsiao <lwhsiao@stanford.edu>2019-11-17 06:29:30 +0300
commitd3f069931bab8b9fc09d7d16096dc62c2d1c8c13 (patch)
treee92f11b2077a39a21d00c377d5e4a8b158fde60b /layouts
parent61357c080fb8364d81649f451a69d5dbe2e7de35 (diff)
build: update for Hugo v0.57+
In Hugo v0.57.0, a breaking change was introduced to the `.Pages` variable [1]. This adopts the new .Site.RegularPages syntax. https://github.com/gohugoio/hugo/issues/6153
Diffstat (limited to 'layouts')
-rwxr-xr-xlayouts/_default/list.html2
-rw-r--r--layouts/index.html2
2 files changed, 2 insertions, 2 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index 4126e13..3d724ce 100755
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -1,6 +1,6 @@
{{ partial "header.html" . }}
<h2 class="c-title p-tag-title">{{ .Title }}</h2>
-{{ range $index, $page := (.Paginate (where .Data.Pages "Type" "posts")).Pages }}
+{{ range $index, $page := (.Paginate (where .Site.RegularPages "Type" "posts")).Pages }}
{{ if ne $index 0 }}
{{ end }}
{{ .Render "li" }}
diff --git a/layouts/index.html b/layouts/index.html
index b4df7b7..9d01f6a 100644
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -1,5 +1,5 @@
{{ partial "header.html" . }}
-{{ range $index, $page := (.Paginate (where (where .Data.Pages "Type" "posts") ".Params.hidden" "!=" "true" )).Pages }}
+{{ range $index, $page := (.Paginate (where (where .Site.RegularPages "Type" "posts") ".Params.hidden" "!=" "true" )).Pages }}
{{ if ne $index 0 }}
{{ end }}
{{ .Render "li" }}