mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-08-29 12:26:35 +02:00
fix: #9301, dont call sitemapstream if there are no entries in categories/pages/topics.xml
This commit is contained in:
@@ -1,12 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
|
||||
{{{ if pages }}}
|
||||
<sitemap>
|
||||
<loc>{url}/sitemap/pages.xml</loc>
|
||||
</sitemap>
|
||||
{{{ end }}}
|
||||
{{{ if categories }}}
|
||||
<sitemap>
|
||||
<loc>{url}/sitemap/categories.xml</loc>
|
||||
</sitemap>
|
||||
{{{ each topics }}}
|
||||
{{{ end }}}
|
||||
{{{ each topics }}}
|
||||
<sitemap>
|
||||
<loc>{url}/sitemap/topics.{@value}.xml</loc>
|
||||
</sitemap>
|
||||
|
||||
Reference in New Issue
Block a user