@infrab4a/connect-angular 4.0.3 → 4.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1582,8 +1582,15 @@ class CategoryService {
1582
1582
  }, mainGender || this.shop === Shops.MENSMARKET ? 'male' : 'female')
1583
1583
  .then(({ data }) => Object.keys(data.map((product) => product.brand).reduce((brands, brand) => ({ ...brands, [brand]: true }), {})));
1584
1584
  return this.categoryRepository
1585
- .find({ filters: { brandCategory: true }, orderBy: { name: 'asc' } })
1586
- .then(({ data }) => data.filter((category) => brands.includes(category.conditions.brand)));
1585
+ .find({
1586
+ filters: {
1587
+ brandCategory: true,
1588
+ conditions: { brand: { operator: Where.IN, value: brands } },
1589
+ shop: this.shop,
1590
+ },
1591
+ orderBy: { name: 'asc' },
1592
+ })
1593
+ .then(({ data }) => data);
1587
1594
  }
1588
1595
  async fetchFilterOptions(category) {
1589
1596
  return await this.categoryFilterRepository