diff --git a/src/themes/default/components/core/blocks/Checkout/ThankYouPage.vue b/src/themes/default/components/core/blocks/Checkout/ThankYouPage.vue
index 1e948053e8..f5f107ceae 100644
--- a/src/themes/default/components/core/blocks/Checkout/ThankYouPage.vue
+++ b/src/themes/default/components/core/blocks/Checkout/ThankYouPage.vue
@@ -4,7 +4,6 @@
diff --git a/src/themes/default/components/core/blocks/SearchPanel/SearchPanel.vue b/src/themes/default/components/core/blocks/SearchPanel/SearchPanel.vue
index fe1f5aacb1..0a20c5805b 100644
--- a/src/themes/default/components/core/blocks/SearchPanel/SearchPanel.vue
+++ b/src/themes/default/components/core/blocks/SearchPanel/SearchPanel.vue
@@ -112,13 +112,17 @@ export default {
return productList
},
categories () {
- const categoriesMap = {}
- this.products.forEach(product => {
- [...product.category].forEach(category => {
- categoriesMap[category.category_id] = category
- })
- })
- return Object.keys(categoriesMap).map(categoryId => categoriesMap[categoryId])
+ const categories = this.products
+ .filter(p => p.category)
+ .map(p => p.category)
+ .flat()
+ .filter(c => c.name)
+
+ const discinctCategories = Array.from(
+ new Set(categories.map(c => c.category_id))
+ ).map(catId => categories.find(c => c.category_id === catId))
+
+ return discinctCategories
},
getNoResultsMessage () {
let msg = ''
diff --git a/src/themes/default/pages/Compare.vue b/src/themes/default/pages/Compare.vue
index 2fb2619993..2e10b999ce 100644
--- a/src/themes/default/pages/Compare.vue
+++ b/src/themes/default/pages/Compare.vue
@@ -2,7 +2,7 @@