diff options
| author | trisusilo48 <tri.susilo@altama.co.id> | 2024-07-16 15:02:35 +0700 |
|---|---|---|
| committer | trisusilo48 <tri.susilo@altama.co.id> | 2024-07-16 15:02:35 +0700 |
| commit | 30e82c4fdec5869ce7020a1ce93a60ad10f32a2f (patch) | |
| tree | 218d61cc1ff078eda5b958e1b5b88af1411cb937 /src/lib/checkout | |
| parent | ccb5ea650de36e537802893d0abb351739b480b8 (diff) | |
| parent | d78382beb19a1d3714d1c203f933393c702e7369 (diff) | |
Merge branch 'development' of https://bitbucket.org/altafixco/next-indoteknik into development
Diffstat (limited to 'src/lib/checkout')
| -rw-r--r-- | src/lib/checkout/components/Checkout.jsx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/checkout/components/Checkout.jsx b/src/lib/checkout/components/Checkout.jsx index 73040425..081ad9a4 100644 --- a/src/lib/checkout/components/Checkout.jsx +++ b/src/lib/checkout/components/Checkout.jsx @@ -243,7 +243,8 @@ const Checkout = () => { setProducts(cartCheckout?.products); setCheckWeight(cartCheckout?.hasProductWithoutWeight); setTotalWeight(cartCheckout?.totalWeight.g); - setHasFlashSale(cartCheckout?.products[0]?.hasFlashsale ? cartCheckout.products[0].hasFlashsale : false); + const hasFlashSale = cartCheckout?.products.some(product => product.hasFlashsale); + setHasFlashSale(hasFlashSale); }, [cartCheckout]); useEffect(() => { |
