swell-js 3.18.2 → 3.19.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{api-b810ea57.js → api-896f20cf.js} +2 -2
- package/dist/api.js +2 -2
- package/dist/index.js +2 -2
- package/dist/{payment-ed203c03.js → payment-4030605c.js} +33 -25
- package/dist/payment.js +1 -1
- package/dist/swell.cjs.js +33 -25
- package/dist/swell.cjs.js.map +1 -1
- package/dist/swell.umd.min.js +13 -8
- package/dist/swell.umd.min.js.map +1 -1
- package/package.json +3 -2
package/dist/swell.umd.min.js
CHANGED
|
@@ -10956,7 +10956,7 @@
|
|
|
10956
10956
|
return;
|
|
10957
10957
|
}
|
|
10958
10958
|
const { error: setupIntentError } = await stripe.confirmCardSetup(
|
|
10959
|
-
authorization.client_secret
|
|
10959
|
+
toSnake(authorization).client_secret
|
|
10960
10960
|
);
|
|
10961
10961
|
return setupIntentError ? { error: setupIntentError } : authorization.card;
|
|
10962
10962
|
}
|
|
@@ -11624,17 +11624,22 @@
|
|
|
11624
11624
|
}, stripeCustomer ? { customer: stripeCustomer } : {})
|
|
11625
11625
|
}).catch(onError)
|
|
11626
11626
|
);
|
|
11627
|
-
if (intent &&
|
|
11628
|
-
|
|
11629
|
-
|
|
11630
|
-
|
|
11631
|
-
|
|
11627
|
+
if (intent && ["requires_capture", "requires_confirmation"].includes(intent.status)) {
|
|
11628
|
+
if (intent.status === "requires_confirmation") {
|
|
11629
|
+
const { error } = await stripe.confirmCardPayment(
|
|
11630
|
+
intent.client_secret
|
|
11631
|
+
);
|
|
11632
|
+
if (error) {
|
|
11633
|
+
return onError(error);
|
|
11634
|
+
}
|
|
11635
|
+
}
|
|
11636
|
+
return await methods$8(request, options$1).update({
|
|
11632
11637
|
billing: {
|
|
11633
11638
|
method: "card",
|
|
11634
11639
|
card: paymentMethod,
|
|
11635
11640
|
intent: {
|
|
11636
11641
|
stripe: __spreadValues$1({
|
|
11637
|
-
id:
|
|
11642
|
+
id: intent.id
|
|
11638
11643
|
}, !!auth_total && {
|
|
11639
11644
|
auth_amount: auth_total
|
|
11640
11645
|
})
|
|
@@ -12123,7 +12128,7 @@
|
|
|
12123
12128
|
previewContent: null
|
|
12124
12129
|
};
|
|
12125
12130
|
const api = {
|
|
12126
|
-
version: "3.
|
|
12131
|
+
version: "3.19.2",
|
|
12127
12132
|
options,
|
|
12128
12133
|
request,
|
|
12129
12134
|
init(store, key, opt = {}) {
|