Обновил проверку закрытия формы ввода карты

This commit is contained in:
dev.daminik00 2024-12-31 03:09:38 +03:00
parent aaedc42362
commit a2a19ffd5b

View File

@ -72,10 +72,10 @@ function TrialPaymentPage() {
}, [isPaymentSuccess]) }, [isPaymentSuccess])
useEffect(() => { useEffect(() => {
if (isModalClosed) { if (isModalClosed && !isPaymentSuccess) {
return handleDiscount() return handleDiscount()
} }
}, [isModalClosed]) }, [isModalClosed, isPaymentSuccess])
useEffect(() => { useEffect(() => {
if (error?.length && error !== "Product not found") { if (error?.length && error !== "Product not found") {