fix: filter bundles from homepage, sitemap, and static params
Some checks failed
Build and Deploy / build (push) Has been cancelled
Some checks failed
Build and Deploy / build (push) Has been cancelled
This commit is contained in:
@@ -20,7 +20,10 @@ export async function generateStaticParams() {
|
||||
try {
|
||||
const saleorLocale = locale === "sr" ? "SR" : "EN";
|
||||
const products = await getProducts(saleorLocale, 100);
|
||||
products.forEach((product: Product) => {
|
||||
const filteredProducts = products.filter(
|
||||
(p: Product) => !p.name.includes("2x Set") && !p.name.includes("3x Set")
|
||||
);
|
||||
filteredProducts.forEach((product: Product) => {
|
||||
params.push({ locale, slug: product.slug });
|
||||
});
|
||||
} catch (e) {
|
||||
|
||||
Reference in New Issue
Block a user