From 19db5a7e1d393168f19f00ff69008395c5c0ce5c Mon Sep 17 00:00:00 2001 From: okbel Date: Thu, 18 Feb 2021 13:24:46 -0300 Subject: [PATCH] Removing bug with touchstart --- components/product/ProductSlider/ProductSlider.tsx | 10 ++++++---- framework/bigcommerce/config.json | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/components/product/ProductSlider/ProductSlider.tsx b/components/product/ProductSlider/ProductSlider.tsx index 4ea7d2ec4..02244f5ba 100644 --- a/components/product/ProductSlider/ProductSlider.tsx +++ b/components/product/ProductSlider/ProductSlider.tsx @@ -50,10 +50,12 @@ const ProductSlider: FC = ({ children }) => { ) return () => { - sliderContainerRef.current!.removeEventListener( - 'touchstart', - preventNavigation - ) + if (sliderContainerRef.current) { + sliderContainerRef.current!.removeEventListener( + 'touchstart', + preventNavigation + ) + } } }, []) diff --git a/framework/bigcommerce/config.json b/framework/bigcommerce/config.json index a0e7afc5d..17ef37e25 100644 --- a/framework/bigcommerce/config.json +++ b/framework/bigcommerce/config.json @@ -1,5 +1,5 @@ { "features": { - "wishlist": true + "wishlist": false } }