diff --git a/react/hooks/useSession.ts b/react/hooks/useSession.ts index ed1ea938e..ceced56aa 100644 --- a/react/hooks/useSession.ts +++ b/react/hooks/useSession.ts @@ -27,7 +27,7 @@ const useSession = () => { } return JSON.parse(data.namespaces.public.shippingOption.value) - }, []) + }, [rootPath]) return { getSession } } diff --git a/react/utils/compatibilityLayer.js b/react/utils/compatibilityLayer.js index c1f2d9f1c..583bff626 100644 --- a/react/utils/compatibilityLayer.js +++ b/react/utils/compatibilityLayer.js @@ -54,7 +54,7 @@ export const buildSelectedFacetsAndFullText = (query, map, priceRange) => { } const addMap = facet => { - facet['map'] = facet.key + facet.map = facet.key if (facet.children) { facet.children.forEach(facetChild => addMap(facetChild))