I’m trying to get a range of pages where lastmod is later than a Unix date that I specify in site frontmatter.
- Range on $test1 gives me the expected pages, with expected Unix date integers : OK
- Range on $test2 is always empty, no matter how I mess around with the where operators
{{ $test1 := ( site.Pages.ByLastmod | last 12).Reverse }}
{{ range $test1 }}
<p> #1 Date {{ .Lastmod.Unix }} updatebase {{ site.Params.updatebase }} {{.Title }}</p>
{{ end }}
{{ $test2 := ( ( where site.Pages.ByLastmod .Lastmod.Unix "gt" site.Params.updatebase )| last 12).Reverse }}
{{ range $test2 }}
<p> #2 Date {{ .Lastmod.Unix }} updatebase {{ site.Params.updatebase }} {{.Title }}</p>
{{ end }}
I’m sure it must be simple. but I cannot see it…
Thanks so much for a hint.