Skip to content

Commit

Permalink
Merge pull request #2164 from graphcommerce-org/bug/GCOM-1306-filters…
Browse files Browse the repository at this point in the history
…-not-applied-properly

Filters not applied properly (GCOM-1306)
  • Loading branch information
paales authored Jan 15, 2024
2 parents 63fe912 + 5224755 commit 39cd68b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/metal-falcons-applaud.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphcommerce/magento-product": patch
---

Fixed filters dissapearing when no items are found with applied filters
2 changes: 1 addition & 1 deletion examples/magento-graphcms/pages/search/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ function SearchResultPage(props: SearchResultProps) {
<NoSearchResults search={search} />
</Container>
)}
{products && products.items && products?.items?.length > 0 && (
{((products && products.items && products?.items?.length > 0) || params.filters) && (
<SearchFilterLayout
params={params}
filters={filters}
Expand Down

0 comments on commit 39cd68b

Please sign in to comment.