This commit is contained in:
Kenneth Jannette
2024-01-19 18:00:10 -06:00
parent 670b76a607
commit 7b0255374c

View File

@@ -109,16 +109,18 @@ const SignupPage = () => {
if (isBusy) { if (isBusy) {
return; return;
} }
const dataValues = validateData(); const dataValues = validateData();
if (dataValues === null) { if (dataValues === null) {
return; return;
} }
setShowPaymentModal(true); setShowPaymentModal(true);
}; };
async function handleStripeAuthorization() {} async function handleStripeAuthorization(paymentDataValues) {
//Do calls to Stripe API
// if success, return some truthy value or
// handleFailure()
}
const handleSignUp = async (e) => { const handleSignUp = async (e) => {
e.preventDefault(); e.preventDefault();
@@ -130,8 +132,9 @@ const SignupPage = () => {
if (dataValues === null) { if (dataValues === null) {
return; return;
} }
//const paymentSuccess = handleStripeAuthorization(paymentDataValues)
setIsBusy(true); setIsBusy(true);
const paymentSuccess = "true"; // handleStripeAuthorization(paymentDataValues)
if (paymentSuccess) {
try { try {
const userCredential = await createUserWithEmailAndPassword( const userCredential = await createUserWithEmailAndPassword(
auth, auth,
@@ -147,6 +150,7 @@ const SignupPage = () => {
error.message || "Sorry, something went wrong. Please try again." error.message || "Sorry, something went wrong. Please try again."
); );
} }
}
}; };
return ( return (