mirror of
https://github.com/thomasjsn/hugo-theme-hello-friend.git
synced 2024-12-25 23:39:27 +01:00
Fix list.html #87
This commit is contained in:
parent
7427cfa3b4
commit
819b0dc373
@ -2,7 +2,12 @@
|
||||
<div class="posts">
|
||||
{{ $isntDefault := not (or (eq (trim $.Site.Params.contentTypeName " ") "posts") (eq (trim $.Site.Params.contentTypeName " ") "")) }}
|
||||
{{ $contentTypeName := cond $isntDefault (string $.Site.Params.contentTypeName) "posts" }}
|
||||
{{ $paginator := .Paginate (where .Site.RegularPages "Type" $contentTypeName) }}
|
||||
|
||||
{{ $PageContext := . }}
|
||||
{{ if .IsHome }}
|
||||
{{ $PageContext = .Site }}
|
||||
{{ end }}
|
||||
{{ $paginator := .Paginate (where $PageContext.RegularPages "Type" $contentTypeName) }}
|
||||
|
||||
{{ range $paginator.Pages }}
|
||||
<div class="post on-list">
|
||||
|
Loading…
Reference in New Issue
Block a user