From 6f8888387f2fb68db6ace6b38fefa034081b0ff7 Mon Sep 17 00:00:00 2001 From: Jan Henckens Date: Wed, 30 Oct 2019 20:51:31 +0100 Subject: [PATCH] Fixed #14, cache sitemap sections with the correct key --- src/services/SitemapService.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/services/SitemapService.php b/src/services/SitemapService.php index 81565a4..4df3fad 100644 --- a/src/services/SitemapService.php +++ b/src/services/SitemapService.php @@ -151,7 +151,7 @@ public function getSitemapData($siteId, $type, $sectionId) if (!Craft::$app->getConfig()->general->devMode) { $data = Craft::$app->getCache()->getOrSet( - '', + self::SITEMAP_CACHE_KEY . "_" . $siteId . "_" . $sectionId, function () use ($data, $type, $settings, $sectionId) { return $this->_addElementsToSitemap($data, $settings[$type][$sectionId]); },