From f10e5f96eba16c020d075635f7bf06500e2c7f5b Mon Sep 17 00:00:00 2001 From: Egor fureunoir Gorbunov Date: Wed, 9 Jul 2025 02:30:57 +0300 Subject: [PATCH] Features: 1) Add filter to exclude products with null stocks and inactive vendors in sitemaps query; Fixes: None; Extra: None; --- core/sitemaps.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/sitemaps.py b/core/sitemaps.py index a9be70d8..a3d79c09 100644 --- a/core/sitemaps.py +++ b/core/sitemaps.py @@ -16,6 +16,8 @@ class ProductSitemap(Sitemap): is_active=True, brand__is_active=True, category__is_active=True, + stocks__isnull=False, + stocks__vendor__is_active=True, ) .only("uuid", "name", "modified", "slug") .order_by("-modified")