jandecaluwe / urubu

A micro CMS for static websites, with a focus on good navigation practices.
urubu.jandecaluwe.com
GNU Affero General Public License v3.0
179 stars 36 forks source link

Search breaks if any pages have no content #89

Closed jshaffstall closed 2 years ago

jshaffstall commented 2 years ago

In my site I have some pages that that have no content, and do not get HTML files generated for them. They exist to be parents in a sidebar hierarchy.

In processors.py, there's this code in make_tipuesearch_content:

        for info in itertools.chain(self.filelist, taglist):
            if 'text' not in info:
                return

That aborts generating the search json file if any page does not have content. Instead, it should continue:

        for info in itertools.chain(self.filelist, taglist):
            if 'text' not in info:
                continue

So that those pages with content can be searched, while leaving the pages without content out.

josyb commented 2 years ago

@LorenzoAncora fixed this in PR #90