diff --git a/src/Payments/CardPayment.res b/src/Payments/CardPayment.res index 7ee064e0b..b9e3d648e 100644 --- a/src/Payments/CardPayment.res +++ b/src/Payments/CardPayment.res @@ -103,13 +103,13 @@ let make = ( ~isCvcValidValue, ) - let isCustomerAcceptanceRequired = React.useMemo1(() => { + let isCustomerAcceptanceRequired = React.useMemo2(() => { if displaySavedPaymentMethodsCheckbox { isSaveCardsChecked || list.payment_type === SETUP_MANDATE } else { !(isGuestCustomer || list.payment_type === NORMAL) } - }, [isSaveCardsChecked]) + }, (isSaveCardsChecked, list.payment_type)) let submitCallback = React.useCallback6((ev: Window.event) => { let json = ev.data->JSON.parseExn