Merge pull request #81 from jvalecillos/patch/post-list-hugo-v0.57.0

This should fix the issue with Hugo's breaking changes since v0.57 as mentioned in https://github.com/gohugoio/hugoThemes/issues/678.
- adjusted post list for Hugo v0.57.0
Credits: @jvalecillos.
This commit is contained in:
Huy Tran 2019-08-19 10:46:46 +10:00 committed by GitHub
commit 19b2178a41
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,7 +4,7 @@
{{ define "content" }}
<div class="post-list">
{{ $paginator := .Paginate (where .Data.Pages "Type" "posts") }}
{{ $paginator := .Paginate (where .Site.RegularPages "Type" "in" site.Params.mainSections) }}
{{ range $paginator.Pages }}
{{ if .Draft }}
{{ .Scratch.Set "draftPage" true }}