diff --git a/src/Sitemaps/Sitemap.php b/src/Sitemaps/Sitemap.php index 424b1a2..bc82d3d 100644 --- a/src/Sitemaps/Sitemap.php +++ b/src/Sitemaps/Sitemap.php @@ -91,6 +91,7 @@ public function getSitemapItems() ->where('collection', $this->handle) ->where('site', Site::current()->handle()) ->where('redirect', '=', null) + ->where('date', '<=', now()) // Exclude future posts by checking the post date is less than or equal to today ->get(); break; case 'taxonomy':