Skip to content

Commit

Permalink
Using site.Params.mainSections for listing posts
Browse files Browse the repository at this point in the history
  • Loading branch information
jvalecillos committed Aug 18, 2019
1 parent 1c50bcc commit 350fe18
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion layouts/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

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

0 comments on commit 350fe18

Please sign in to comment.