Pages in root section included when selecting those of another Section

I want to range over pages in my blog section (content/blog) and use this line:

{{ with (where .Site.RegularPages.ByDate.Reverse ".Section" "in" "blog") }}

The problem is that the pages directly under content are also included. However, those that are in another section are not, so there is obviously some use of where in this case.

How do I get an array of just the pages in a specific section?

Replacing “in” by “eq” fixes it. No idea why “in” doesn’t work though. The root pages aren’t reasonably in the “blog” section.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.