#daniyal_11692

1 messages · Page 1 of 1 (latest)

meager cragBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

rose dove
#

hi there!

#

what are you doing exactly that's causing this error?

vocal knot
#

hi, when i click on gPay as an option from payment element. this error is shown in console

rose dove
#

and is Google Pay working or not?

vocal knot
#

not working

rose dove
#

can you share a link to reproduce the issue?

meager cragBOT
vocal knot
#

here's a screen cast on how to reproduce

#

you should be in iphone SE in repponsive options then GPAY will appear

#

just like in screencast

mystic barn
#

Can you share your code that handles the 'place order' click and triggers confirmPayment?

vocal knot
#

async function confirmPaymentSetup() {
var button = document.getElementById('submit');
button.innerText = pleaseWaitText;
button.disabled = true;

    elements.submit();
    await stripe.confirmSetup({
        elements,
        clientSecret,
        redirect: 'if_required'
    }).then(function (result) {
        console.log(1)
        console.log(result);
        doPost({ loading: true });
        if (result.error) {
            button.innerText = buttonText;
            button.disabled = false;
            doPost({ loading: false, error: true, message: result.error.message });
        } else {
            doPost({ loading: false, error: false, message: authorizedText, response: result });
        }
    })
}
#

const stripe = Stripe(stripePublishableKey, { locale: getQueryParam('lang'), apiVersion: '2020-08-27', });
const stripeElementOptions = {
mode: 'setup',
currency: billingCurrency,
paymentMethodTypes: ['card']
}

mystic barn
vocal knot
#

let me see

#

it worked.

#

many thanks

#

i did just this: await elements.submit()