/* Metro module 4226; source: modules/billing/actions/BillingPaymentGatewayActionCreators.tsx; dependencies: [5, 661, 482, 3, 507, 1244, 4224, 4227, 694, 44, 4228, 4229, 3824, 4131, 2] */ function _fun34706(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#34706, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:6, offset: 0x0105fb90, size: 775 bytes, params: 8, frame: 24 const env0_0 = require; const closure = createAdyenPaymentSourceToken; const closure2 = dispatchPaymentElementsConfirmationError; const closure3 = function() { return _createStripePaymentSourceToken.apply(this, arguments); }; const performRedirect = function(a0) { global.window.open(a0); }; const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); const env0_4 = importDefault(5) /* metro dependency 5 */; let value = require(661) /* metro dependency 661: Constants */; const env0_5 = value.Endpoints; const env0_6 = value.PaymentGateways; const env0_7 = value.REDIRECTED_PAYMENT_SOURCES; const env0_8 = value.VAULTABLE_PAYMENT_SOURCES; value = require(482) /* metro dependency 482: Constants */; const env0_9 = value.ADYEN_PAYMENT_SOURCES; const env0_10 = value.STRIPE_PAYMENT_SOURCES; const PaymentSourceTypes = value.PaymentSourceTypes; value = importDefault(3) /* metro dependency 3: Logger */; value = new value('BillingPaymentGatewayActionCreators.tsx'); value = _fun34769(); const env0_15 = _fun34773(); const value3 = _fun34777(); const Set = global.Set; const CARD = PaymentSourceTypes.CARD; const PAYMENT_REQUEST = PaymentSourceTypes.PAYMENT_REQUEST; const PIX = PaymentSourceTypes.PIX; const set = new Set([CARD, PAYMENT_REQUEST, PIX]); (require(2) /* metro dependency 2 */).fileFinishedImporting('modules/billing/actions/BillingPaymentGatewayActionCreators.tsx'); exports.createAdyenPaymentSourceToken = closure; exports.dispatchPaymentElementsConfirmationError = closure2; exports.createCardToken = function() { return _createCardToken.apply(this, arguments); }; exports.confirmEPS = function() { return _confirmEPS.apply(this, arguments); }; exports.confirmIdeal = function() { return _confirmIdeal.apply(this, arguments); }; exports.confirmPrzelewy24 = function() { return _confirmPrzelewy.apply(this, arguments); }; exports.submitElementsForPaymentElement = value; exports.createPaymentRequestMethodForPaymentElement = value3; exports.confirmPaymentElementSource = function() { return _confirmPaymentElementSource.apply(this, arguments); }; exports.confirmCardPaymentSource = function() { return _confirmCardPaymentSource.apply(this, arguments); }; exports.createPaymentRequestPaymentSource = function(a0, a1, a2) { var value = a1; var {token, billingAddressInfo} = importAll(dependencyMap[11]).parseStripePaymentMethod(a0); var moduleValue2 = require(dependencyMap[6]); var createPaymentSource = moduleValue2.createPaymentSource; var STRIPE = PaymentGateways.STRIPE; return Reflect.apply(createPaymentSource, moduleValue2, [STRIPE, token, value ?? billingAddressInfo, {analyticsLocation: a2}]); }; exports.createBraintreePaymentSource = function(a0, a1, a2) { var moduleValue = require(dependencyMap[6]); var BRAINTREE = PaymentGateways.BRAINTREE; return moduleValue.createPaymentSource(BRAINTREE, a0, a1, {analyticsLocation: a2}); }; exports.createStripePaymentSource = function() { return _createStripePaymentSource.apply(this, arguments); }; exports.createAdyenPrepaidPaymentSource = function() { return _createAdyenPrepaidPaymentSource.apply(this, arguments); }; exports.createAdyenVaultablePaymentSource = function() { return _createAdyenVaultablePaymentSource.apply(this, arguments); }; exports.createStripePaymentSourceToken = closure3; exports.createPaymentSourceToken = createPaymentSourceToken; exports.handleAdyenConfirmation = function() { return _handleAdyenConfirmation.apply(this, arguments); }; exports.handleStripeConfirmation = function() { return _handleStripeConfirmation.apply(this, arguments); }; exports.paymentIntentSucceeded = function() { return _paymentIntentSucceeded.apply(this, arguments); }; } function _getClientSecret() { // fn#34707, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:357, offset: 0x0105fe97, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34709).apply(this, arguments); } function _getPaymentIntentInfo() { // fn#34710, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:602, offset: 0x0105ff3f, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34712).apply(this, arguments); } function createAdyenPaymentSourceToken(a0) { // fn#34713, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:938, offset: 0x0105fffb, size: 90 bytes, params: 2, frame: 16 var r0; var JSON; var stringify; var value; const value2 = VAULTABLE_PAYMENT_SOURCES.has(a0.type); const value3 = null; if (value2) { r0 = value3; } else { JSON = global.JSON; stringify = JSON.stringify; value = ADYEN_PAYMENT_SOURCES.get(a0.type); value = Reflect.apply(stringify, JSON, [{type: value3 != value ? value : value3}]); r0 = value; } return r0; } function dispatchPaymentElementsConfirmationError(a0) { // fn#34714, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:1066, offset: 0x01060055, size: 145 bytes, params: 2, frame: 19 var r4; var intl; const value = a1; const value2 = a2; const r5 = !(value !== undefined) || value; if (value2 !== undefined) { r4 = value2; } else { intl = (require(1244) /* metro dependency 1244: indexNative */).intl; r4 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.khEaRI); } return (require(4224) /* metro dependency 4224: BillingSharedActionCreators */).dispatchConfirmationError(a0, r5, r4, {tags: {source: 'payment_elements'}}); } function _createCardToken() { // fn#34715, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:1247, offset: 0x010600e6, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34717).apply(this, arguments); } function _confirmEPS() { // fn#34718, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:1794, offset: 0x01060243, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34720).apply(this, arguments); } function _confirmIdeal() { // fn#34721, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:2769, offset: 0x010604b9, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34723).apply(this, arguments); } function _confirmPrzelewy() { // fn#34724, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:3663, offset: 0x010606ef, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34726).apply(this, arguments); } function _confirmPaymentElementSource() { // fn#34727, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:6243, offset: 0x0106093a, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34729).apply(this, arguments); } function _confirmCardPaymentSource() { // fn#34731, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:7598, offset: 0x01060d69, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34733).apply(this, arguments); } function _createStripePaymentSource() { // fn#34735, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:8419, offset: 0x01060fa8, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34737).apply(this, arguments); } function _createAdyenPrepaidPaymentSource() { // fn#34738, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:9235, offset: 0x010611a4, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34740).apply(this, arguments); } function _createAdyenVaultablePaymentSource() { // fn#34741, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:9550, offset: 0x0106128b, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34743).apply(this, arguments); } function _createStripePaymentSourceToken() { // fn#34745, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:10740, offset: 0x010615a8, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34747).apply(this, arguments); } function _handleAdyenConfirmation() { // fn#34748, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:12225, offset: 0x010619d5, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34750).apply(this, arguments); } function _handleStripeConfirmation() { // fn#34751, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:12665, offset: 0x01061acf, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34753).apply(this, arguments); } function _paymentIntentSucceeded() { // fn#34757, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:13585, offset: 0x01061cef, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34759).apply(this, arguments); } function _confirmPayments() { // fn#34762, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:14413, offset: 0x01061ee4, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34764).apply(this, arguments); } function _getStripeRedirect() { // fn#34765, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:15051, offset: 0x01062051, size: 48 bytes, params: 1, frame: 14 return env0_4(_fun34767).apply(this, arguments); } function validateSetupIntentResponse(a0, a1, a2) { // fn#34768, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:4624, offset: 0x0106249f, size: 135 bytes, params: 4, frame: 16 if (a1 != null) { throw a2(a1); } if (a0 == null) { throw a2('SetupIntent not created'); } if (a0.payment_method == null) { throw a2('setupIntent.payment_method not available with successful stripe call'); } (importDefault(44) /* metro dependency 44 */)(typeof a0.payment_method === 'string', 'setupIntent.payment_method expanded not supported'); return {setupIntent: a0, error: a1}; } function _fun34769() { // fn#34769, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:4937, offset: 0x01062526, size: 32 bytes, params: 1, frame: 12 const env0_0 = env0_4(_fun34771); return _fun34772; } function _fun34773() { // fn#34773, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:5323, offset: 0x010625e9, size: 32 bytes, params: 1, frame: 12 const env0_0 = env0_4(_fun34775); return _fun34776; } function _fun34777() { // fn#34777, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:5853, offset: 0x010626cb, size: 32 bytes, params: 1, frame: 12 const env0_0 = env0_4(_fun34779); return _fun34780; } function createPaymentSourceToken(a0) { // fn#34792, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:18673, offset: 0x01062851, size: 81 bytes, params: 2, frame: 14 return VAULTABLE_PAYMENT_SOURCES.has(a0.type) ? null : ADYEN_PAYMENT_SOURCES.has(a0.type) ? createAdyenPaymentSourceToken(a0) : createStripePaymentSourceToken(a0); } function* _fun34709(a0) { // fn#34709, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:412, offset: 0x0105fed0, size: 111 bytes, params: 2, frame: 15 if (false) { return undefined; } value = environment.__proto__.__proto__; const HTTP = env2_0(env2_3[4]).HTTP; const get = HTTP.get; const object2 = {'url': null, 'oldFormErrors': true, 'rejectWithError': true}; object2.url = env2_5.BILLING_STRIPE_PAYMENT_INTENTS(a0); yield Reflect.apply(get, HTTP, [object2]); value = undefined; if (false) { return value; } return value.body.stripe_payment_intent_client_secret; } function* _fun34712(a0) { // fn#34712, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:667, offset: 0x0105ff78, size: 131 bytes, params: 2, frame: 15 if (false) { return undefined; } value = environment.__proto__.__proto__; const HTTP = env2_0(env2_3[4]).HTTP; const get = HTTP.get; const object2 = {'url': null, 'oldFormErrors': true, 'rejectWithError': true}; object2.url = env2_5.BILLING_STRIPE_PAYMENT_INTENTS(a0); yield Reflect.apply(get, HTTP, [object2]); value = undefined; if (false) { return value; } const body = value.body; return {clientSecret: body.stripe_payment_intent_client_secret, paymentMethodId: body.stripe_payment_intent_payment_method_id}; } function* _fun34717(a0, a1) { // fn#34717, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:1302, offset: 0x0106011f, size: 292 bytes, params: 3, frame: 17 let value = undefined; if (false) { return value; } if (a0 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe or elements not loaded'); } if (a1 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe or elements not loaded'); } const getElement = a1.getElement; value = environment.__proto__.__proto__; const CardNumberElement = env2_0(env2_3[7]).CardNumberElement; const value3 = Reflect.apply(getElement, a1, [CardNumberElement]); if (value3 == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Unable to load card elements from Stripe'); } yield a0.createToken(value3); const value4 = undefined; if (false) { return value4; } const token = value4.token; const error = value4.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (token == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('token not available with successful stripe call'); } return token.id; } function* _fun34720(a0, a1, a2, a3) { // fn#34720, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:1839, offset: 0x0106027c, size: 573 bytes, params: 5, frame: 32 let value = undefined; if (false) { return value; } if (a0 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe not loaded'); } if (a1 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Bank required for EPS'); } const email = a2.email; const name = a2.name; const line1 = a2.line1; const line2 = a2.line2; const city = a2.city; const state = a2.state; const postalCode = a2.postalCode; const country = a2.country; if (name == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Name required for EPS'); } value = environment.__proto__.__proto__; const binding = env2_1; const binding2 = env2_3; binding(binding2[8]).dispatch({type: 'BILLING_PAYMENT_SOURCE_CREATE_START'}); const value4 = env2_0(binding2[6]); yield value4.validatePaymentSourceBillingAddress(a2); const value5 = undefined; if (false) { return value5; } yield a0.createPaymentMethod({type: 'eps', eps: {bank: a1}, billing_details: {address: {line1: line1, line2: line2, city: city, state: state, postal_code: postalCode, country: country}, name: name, email: email}}); const value7 = undefined; if (false) { return value7; } const paymentMethod = value7.paymentMethod; const error = value7.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentMethod == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentMethod not available with successful stripe call'); } const value9 = env2_0(env2_3[6]); const createPaymentSource = value9.createPaymentSource; const STRIPE = env2_6.STRIPE; return Reflect.apply(createPaymentSource, value9, [STRIPE, paymentMethod.id, a2, {billingAddressToken: value5, analyticsLocation: a3, bank: a1}]); } function* _fun34723(a0, a1, a2) { // fn#34723, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:2818, offset: 0x010604f2, size: 509 bytes, params: 4, frame: 31 let value = undefined; if (false) { return value; } if (a0 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe not loaded'); } const email = a1.email; const name = a1.name; const line1 = a1.line1; const line2 = a1.line2; const city = a1.city; const state = a1.state; const postalCode = a1.postalCode; const country = a1.country; if (name == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Name required for iDEAL'); } value = environment.__proto__.__proto__; const binding = env2_1; const binding2 = env2_3; binding(binding2[8]).dispatch({type: 'BILLING_PAYMENT_SOURCE_CREATE_START'}); const value4 = env2_0(binding2[6]); yield value4.validatePaymentSourceBillingAddress(a1); const value5 = undefined; if (false) { return value5; } yield a0.createPaymentMethod({type: 'ideal', ideal: {}, billing_details: {address: {line1: line1, line2: line2, city: city, state: state, postal_code: postalCode, country: country}, name: name, email: email}}); const value7 = undefined; if (false) { return value7; } const paymentMethod = value7.paymentMethod; const error = value7.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentMethod == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentMethod not available with successful stripe call'); } const value9 = env2_0(env2_3[6]); const createPaymentSource = value9.createPaymentSource; const STRIPE = env2_6.STRIPE; return Reflect.apply(createPaymentSource, value9, [STRIPE, paymentMethod.id, a1, {billingAddressToken: value5, analyticsLocation: a2}]); } function* _fun34726(a0, {p24Bank}, a2, a3) { // fn#34726, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:3718, offset: 0x01060728, size: 530 bytes, params: 5, frame: 32 let value = undefined; if (false) { return value; } if (a0 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe not loaded'); } const email = a2.email; const name = a2.name; const line1 = a2.line1; const line2 = a2.line2; const city = a2.city; const state = a2.state; const postalCode = a2.postalCode; const country = a2.country; if (email == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Email required for Przelewy24'); } value = environment.__proto__.__proto__; const binding = env2_1; const binding2 = env2_3; binding(binding2[8]).dispatch({type: 'BILLING_PAYMENT_SOURCE_CREATE_START'}); const value4 = env2_0(binding2[6]); yield value4.validatePaymentSourceBillingAddress(a2); if (false) { return undefined; } yield a0.createPaymentMethod({type: 'p24', p24: {bank: p24Bank}, billing_details: {address: {line1: line1, line2: line2, city: city, state: state, postal_code: postalCode, country: country}, name: name, email: email}}); if (false) { return undefined; } const paymentMethod = undefined.paymentMethod; const error = undefined.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentMethod == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentMethod not available with successful stripe call'); } const value9 = env2_0(env2_3[6]); const createPaymentSource = value9.createPaymentSource; const STRIPE = env2_6.STRIPE; return Reflect.apply(createPaymentSource, value9, [STRIPE, paymentMethod.id, a2, {billingAddressToken: undefined, analyticsLocation: a3, bank: p24Bank}]); } async function _fun34729(a0) { // fn#34729, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:6322, offset: 0x0106097c, size: 983 bytes, params: 2, frame: 38 var environment; var r2; var r3; var r42; var r43; var r44; var r19; var r11; var r9; var item3; var value4; var item4; var value5; var billingAddress; var paymentSourceType; var lastConfirmedSetupIntentRef; var item5; var value6; var value16; var confirmSetup; var value18; var error; var setup_intent; var status; var value20; var value21; var client_secret; var value25; var setupIntent; var value27; var value28; if (false) { return undefined; } const iterator = copyRestArgs(0, undefined)[Symbol.iterator](); const iterator2 = iterator.next; value = undefined; let item2 = Reflect.apply(iterator2, iterator, []); let item = item2.value; item2 = item2.done ? undefined : iterator; const value3 = item2 === value; const r4 = value3 ? value : item; if (value3) { r2 = item2; r3 = value3; r42 = value; } else { item3 = Reflect.apply(iterator2, item2, []); item = item3.value; item3 = item3.done ? undefined : item2; value4 = item3 === value; if (value4) { r2 = item3; r3 = value4; r42 = value; } else { r2 = item3; r3 = value4; r42 = item; } } if (r3) { r43 = value; } else { item4 = Reflect.apply(iterator2, r2, []); item = item4.value; item4 = item4.done ? undefined : r2; value5 = item4 === value; if (value5) { r2 = item4; r3 = value5; r43 = value; } else { r2 = item4; r3 = value5; r43 = item; } } try { billingAddress = r43.billingAddress; paymentSourceType = r43.paymentSourceType; lastConfirmedSetupIntentRef = r43.lastConfirmedSetupIntentRef; } catch (error) { if (!r3) { try { r2.return(); } catch { } } throw error; } if (r3) { r44 = value; } else { item5 = Reflect.apply(iterator2, r2, []); item = item5.value; item5 = item5.done ? undefined : r2; value6 = item5 === value; if (value6) { r2 = item5; r3 = value6; r44 = value; } else { r2 = item5; r3 = value6; r44 = item; } } if (!r3) { r2.return(); } await value; if (false) { return undefined; } if (r4 == null) { value28 = environment.__proto__.__proto__; throw env2_20('Stripe not loaded', true); } if (r42 == null) { value27 = environment.__proto__.__proto__; throw env2_20('Stripe Elements not loaded', true); } let binding = env2_1; const binding2 = env2_3; binding(binding2[8]).dispatch({type: 'BILLING_PAYMENT_SOURCE_CREATE_START'}); const value11 = env2_0(binding2[6]); await value11.validatePaymentSourceBillingAddress(billingAddress); const value12 = undefined; if (false) { return value12; } let PAYMENT_REQUEST = env2_11.PAYMENT_REQUEST; if (paymentSourceType === PAYMENT_REQUEST) { binding = env2_16; if (binding.has(paymentSourceType)) { r19 = lastConfirmedSetupIntentRef.current ?? value; if (r19 == null) { confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', elements: r42}]); value18 = undefined; if (false) { return value18; } r19 = value18; error = r19.error; if (error == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (error.code !== 'setup_intent_unexpected_state') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; if (setup_intent == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status === 'succeeded') { if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status !== 'canceled') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', clientSecret: client_secret, elements: r42}]); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; error = r11.error; setupIntent = binding(setupIntent, error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } PAYMENT_REQUEST = env2_11.PAYMENT_REQUEST; if (paymentSourceType === PAYMENT_REQUEST) { r19 = {setupIntent: r19 ?? value, error: value}; error = r19.error; if (error == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (error.code !== 'setup_intent_unexpected_state') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; if (setup_intent == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status === 'succeeded') { if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status !== 'canceled') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; error = r11.error; setupIntent = binding(setupIntent, error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', elements: r42}]); value18 = undefined; if (false) { return value18; } r19 = value18; error = r19.error; if (error == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (error.code !== 'setup_intent_unexpected_state') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; if (setup_intent == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status === 'succeeded') { if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status !== 'canceled') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } PAYMENT_REQUEST = env2_11.PAYMENT_REQUEST; if (paymentSourceType === PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', clientSecret: client_secret, elements: r42}]); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; error = r11.error; setupIntent = binding(setupIntent, error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } await env2_15(r4, r42); value16 = undefined; if (false) { return value16; } r9 = value16.paymentMethod.id; binding = env2_0; value = binding(env2_3[6]); } else { await env2_14(r42); if (false) { return undefined; } if (Reflect.apply(env2_16.has, binding, [paymentSourceType])) { r19 = lastConfirmedSetupIntentRef.current ?? value; if (r19 == null) { confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', elements: r42}]); value18 = undefined; if (false) { return value18; } r19 = value18; error = r19.error; if (error == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (error.code !== 'setup_intent_unexpected_state') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; if (setup_intent == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status === 'succeeded') { if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status !== 'canceled') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', clientSecret: client_secret, elements: r42}]); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; error = r11.error; setupIntent = binding(setupIntent, error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } PAYMENT_REQUEST = env2_11.PAYMENT_REQUEST; if (paymentSourceType === PAYMENT_REQUEST) { r19 = {setupIntent: r19 ?? value, error: value}; error = r19.error; if (error == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (error.code !== 'setup_intent_unexpected_state') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; if (setup_intent == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status === 'succeeded') { if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status !== 'canceled') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; error = r11.error; setupIntent = binding(setupIntent, error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', elements: r42}]); value18 = undefined; if (false) { return value18; } r19 = value18; error = r19.error; if (error == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } if (error.code !== 'setup_intent_unexpected_state') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; if (setup_intent == null) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status === 'succeeded') { if (paymentSourceType === env2_11.PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } await r4.confirmSetup({redirect: 'if_required', clientSecret: client_secret, elements: r42}); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } setup_intent = error.setup_intent; status = setup_intent.status; if (status !== 'canceled') { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } PAYMENT_REQUEST = env2_11.PAYMENT_REQUEST; if (paymentSourceType === PAYMENT_REQUEST) { r11 = r19; binding = env2_13; setupIntent = r11.setupIntent; setupIntent = binding(setupIntent, r11.error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } binding = env2_0; value20 = binding(env2_3[10]); await value20.createSetupIntentForPaymentElements(); value21 = undefined; if (false) { return value21; } client_secret = value21.client_secret; await env2_14(r42); if (false) { return undefined; } confirmSetup = r4.confirmSetup; await Reflect.apply(confirmSetup, r4, [{redirect: 'if_required', clientSecret: client_secret, elements: r42}]); value25 = undefined; if (false) { return value25; } r11 = value25; binding = env2_13; setupIntent = r11.setupIntent; error = r11.error; setupIntent = binding(setupIntent, error, _fun34730).setupIntent; lastConfirmedSetupIntentRef.current = setupIntent; r9 = setupIntent.payment_method; binding = env2_0; value = binding(env2_3[6]); return value.createPaymentSource(env2_6.STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}); } await env2_15(r4, r42); value16 = undefined; if (false) { return value16; } r9 = value16.paymentMethod.id; value = env2_0(env2_3[6]); } const createPaymentSource = value.createPaymentSource; const STRIPE = env2_6.STRIPE; return Reflect.apply(createPaymentSource, value, [STRIPE, r9, billingAddress, {billingAddressToken: value12, analyticsLocation: r44}]); } function* _fun34733(a0, a1, a2, a3) { // fn#34733, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:7671, offset: 0x01060da2, size: 477 bytes, params: 5, frame: 28 var environment; var binding; var binding2; var property; var value4; var createStripeSetupIntent; var stripeSetupIntent; var value5; var value6; var client_secret; var error; var dispatchConfirmationError; let value = undefined; if (false) { return value; } if (a0 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe or token not loaded'); } if (a1 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe or token not loaded'); } value = environment.__proto__.__proto__; env2_1(env2_3[8]).dispatch({type: 'BILLING_PAYMENT_SOURCE_CREATE_START'}); try { binding = env2_0; } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } try { binding2 = env2_3; } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } try { property = binding2[10]; } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } try { value4 = binding(property); } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } try { createStripeSetupIntent = value4.createStripeSetupIntent; } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } try { stripeSetupIntent = Reflect.apply(createStripeSetupIntent, value4, []); } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } yield stripeSetupIntent; try { value5 = undefined; value6 = false; } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } if (value6) { return value5; } try { client_secret = value5.client_secret; } catch (error) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, [error]); } const value7 = env2_0(env2_3[6]); yield value7.validatePaymentSourceBillingAddress(a2); const value8 = undefined; if (false) { return value8; } yield a0.confirmCardSetup(client_secret, {payment_method: {card: {token: a1}, billing_details: env2_2(env2_3[11]).parseBillingAddressInfoToStripeBillingDetails(a2)}}); const value11 = undefined; if (false) { return value11; } let setupIntent = value11.setupIntent; setupIntent = env2_13(setupIntent, value11.error, _fun34734).setupIntent; const value13 = env2_0(env2_3[6]); const createPaymentSource = value13.createPaymentSource; const STRIPE = env2_6.STRIPE; return Reflect.apply(createPaymentSource, value13, [STRIPE, setupIntent.payment_method, a2, {billingAddressToken: value8, analyticsLocation: a3}]); } function* _fun34737(a0, a1, a2, a3) { // fn#34737, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:8494, offset: 0x01060fe1, size: 451 bytes, params: 5, frame: 30 let value = undefined; if (false) { return value; } if (a0 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe not loaded'); } value = environment.__proto__.__proto__; const value3 = env2_0(env2_3[6]); yield value3.validatePaymentSourceBillingAddress(a1); const value4 = undefined; if (false) { return value4; } const name = a1.name; const line1 = a1.line1; const line2 = a1.line2; const city = a1.city; const state = a1.state; const postalCode = a1.postalCode; const country = a1.country; const value6 = env2_10.get(a2); env2_1(env2_3[9])(value6 != null, 'unsupported payment method type'); yield a0.createPaymentMethod({type: value6, billing_details: {address: {line1: line1, line2: line2, city: city, state: state, postal_code: postalCode, country: country}, name: name}}); const value8 = undefined; if (false) { return value8; } const paymentMethod = value8.paymentMethod; const error = value8.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentMethod == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('stripePaymentMethod not available with successful stripe call'); } const value10 = env2_0(env2_3[6]); const createPaymentSource = value10.createPaymentSource; const STRIPE = env2_6.STRIPE; return Reflect.apply(createPaymentSource, value10, [STRIPE, paymentMethod.id, a1, {billingAddressToken: value4, analyticsLocation: a3}]); } function* _fun34740(a0, a1, a2) { // fn#34740, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:9322, offset: 0x010611dd, size: 174 bytes, params: 4, frame: 21 if (false) { return undefined; } value = environment.__proto__.__proto__; const value3 = env2_0(env2_3[6]); yield value3.validatePaymentSourceBillingAddress(a0); const value4 = undefined; if (false) { return value4; } const object2 = {}; object2.type = env2_9.get(a1); const value6 = env2_0(env2_3[6]); const createPaymentSource = value6.createPaymentSource; const ADYEN = env2_6.ADYEN; const JSON = global.JSON; return Reflect.apply(createPaymentSource, value6, [ADYEN, JSON.stringify(object2), a0, {billingAddressToken: value4, analyticsLocation: a2}]); } async function _fun34743(a0, a1, a2, a3) { // fn#34743, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:9641, offset: 0x010612cd, size: 731 bytes, params: 5, frame: 34 var code; var message; var object2; var binding2; var property; var value16; var createPaymentSource; var ADYEN; var JSON; var stringify; var value17; var paymentSource; var value18; var value19; var error; var ErrorCodes; var CONFIRMATION_REQUIRED; var fields; var adyen_redirect_url; var dispatchConfirmationError; var binding3; var value20; var dispatch; var BillingError; var value21; var BillingError2; var UNKNOWN; var prototype; var billingError; let value = a4; if (false) { return undefined; } const value4 = undefined; const r1 = value !== value4 ? value : false; await value4; if (false) { return undefined; } value = environment.__proto__.__proto__; let binding = env2_0; const value6 = binding(env2_3[6]); await value6.validatePaymentSourceBillingAddress(a0); const value7 = undefined; if (false) { return value7; } let object4 = {}; object4.type = env2_9.get(a1); copyDataProperties(object4, (a3 == null ? value4 : a3.paymentMethod) ?? ({}), undefined); const value9 = env2_0(env2_3[6]); await value9.popupBridgeState(a1); const value10 = undefined; if (false) { return value10; } const aPIBaseURL = env2_0(env2_3[4]).getAPIBaseURL(); binding = env2_5; const BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX = binding.BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX; const value15 = aPIBaseURL + Reflect.apply(BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX, binding, [a1, value10 ?? '', 'success']); try { object2 = {}; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { binding = env2_0; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { binding2 = env2_3; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { property = binding2[6]; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { value16 = binding(property); } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { createPaymentSource = value16.createPaymentSource; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { binding = env2_6; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { ADYEN = binding.ADYEN; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { JSON = global.JSON; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { stringify = JSON.stringify; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { value17 = Reflect.apply(stringify, JSON, [object4]); } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { object4 = {}; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { object4.billingAddressToken = value7; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { object4.analyticsLocation = a2; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { object4.returnUrl = value15; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { paymentSource = Reflect.apply(createPaymentSource, value16, [ADYEN, value17, a0, object4, r1]); } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } await paymentSource; try { value18 = undefined; value19 = false; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } if (value19) { return value18; } try { object2.paymentSource = value18; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } try { object2.redirectConfirmation = false; } catch (error) { code = error.code; binding = env2_0; ErrorCodes = binding(env2_3[12]).ErrorCodes; CONFIRMATION_REQUIRED = ErrorCodes.CONFIRMATION_REQUIRED; if (code !== CONFIRMATION_REQUIRED) { binding = env2_1; binding3 = env2_3; value20 = binding(binding3[8]); dispatch = value20.dispatch; object4 = {type: 'BILLING_PAYMENT_SOURCE_CREATE_FAIL'}; binding = env2_0; BillingError = binding(binding3[13]).BillingError; if (error == null) { code = value4; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + error.message; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } code = error.code; if (error == null) { value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + value4; UNKNOWN = env2_0(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; object4.error = new BillingError(); Reflect.apply(dispatch, value20, [object4]); throw error; } message = error.message; value21 = 'Unable to create payment source token: code: ' + code + ' message: ' + message; binding = env2_0; BillingError2 = binding(env2_3[13]).BillingError; ErrorCodes = BillingError2.ErrorCodes; UNKNOWN = ErrorCodes.UNKNOWN; prototype = BillingError.prototype; value = Object.create(prototype, {constructor: {value: BillingError}}); billingError = new BillingError(); value = billingError instanceof Object ? billingError : value; object4.error = value; Reflect.apply(dispatch, value20, [object4]); throw error; } fields = error.fields; adyen_redirect_url = fields.adyen_redirect_url; if (adyen_redirect_url == null) { binding = env2_0; value = binding(env2_3[6]); dispatchConfirmationError = value.dispatchConfirmationError; throw Reflect.apply(dispatchConfirmationError, value, ['redirect url cannot be null on a redirect for adyen.']); } env2_35(adyen_redirect_url); return {redirectConfirmation: true}; } return object2; } function* _fun34747(a0) { // fn#34747, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:10825, offset: 0x010615e1, size: 1012 bytes, params: 2, frame: 27 var bank; var binding2; var BillingError; var UNKNOWN_PAYMENT_SOURCE; var binding3; var value9; var paymentMethod; var error; var value11; var UNKNOWN; var binding4; if (false) { return undefined; } value = environment.__proto__.__proto__; let binding = env2_8; const has = binding.has; let type = a0.type; if (Reflect.apply(has, binding, [type])) { return null; } binding = env2_2; const value3 = undefined; const value4 = binding(env2_3[11]); const getStripe = value4.getStripe; yield Reflect.apply(getStripe, value4, []); const value5 = undefined; if (false) { return value5; } if (value5 == null) { binding = env2_0; binding4 = env2_3; BillingError = binding(binding4[13]).BillingError; UNKNOWN = binding(binding4[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError('Stripe not loaded'); } const {email, name, line1, line2, city, state, postalCode, country} = a0.billingAddress; const object2 = {}; object2.billing_details = {address: {line1: line1, line2: line2, city: city, state: state, postal_code: postalCode, country: country}, name: name}; type = a0.type; const GIROPAY = env2_11.GIROPAY; if (GIROPAY === type) { object2.type = 'giropay'; env2_1(env2_3[9])(object2.type != null, 'unsupported payment method type'); } else { var SOFORT = env2_11.SOFORT; if (SOFORT === type) { object2.type = 'sofort'; object2.sofort = {country: country ?? ''}; object2.billing_details.email = email; binding = env2_1; binding(env2_3[9])(object2.type != null, 'unsupported payment method type'); yield value5.createPaymentMethod(object2); value9 = undefined; if (false) { return value9; } paymentMethod = value9.paymentMethod; error = value9.error; if (error != null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } if (paymentMethod == null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } return paymentMethod.id; } var BANCONTACT = env2_11.BANCONTACT; if (BANCONTACT === type) { object2.type = 'bancontact'; binding = env2_1; binding(env2_3[9])(object2.type != null, 'unsupported payment method type'); yield value5.createPaymentMethod(object2); value9 = undefined; if (false) { return value9; } paymentMethod = value9.paymentMethod; error = value9.error; if (error != null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } if (paymentMethod == null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } return paymentMethod.id; } var IDEAL = env2_11.IDEAL; if (IDEAL === type) { object2.type = 'ideal'; object2.ideal = {bank: a0.bank}; binding = env2_1; binding(env2_3[9])(object2.type != null, 'unsupported payment method type'); yield value5.createPaymentMethod(object2); value9 = undefined; if (false) { return value9; } paymentMethod = value9.paymentMethod; error = value9.error; if (error != null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } if (paymentMethod == null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } return paymentMethod.id; } var PRZELEWY24 = env2_11.PRZELEWY24; if (PRZELEWY24 === type) { bank = a0.bank; if (bank == null) { binding = env2_0; binding3 = env2_3; BillingError = binding(binding3[13]).BillingError; UNKNOWN_PAYMENT_SOURCE = binding(binding3[13]).BillingError.ErrorCodes.UNKNOWN_PAYMENT_SOURCE; throw new BillingError('p24 missing bank information'); } object2.type = 'p24'; bank = a0.bank; object2.p24 = {bank: bank}; object2.billing_details.email = a0.email; binding = env2_1; binding(env2_3[9])(object2.type != null, 'unsupported payment method type'); yield value5.createPaymentMethod(object2); value9 = undefined; if (false) { return value9; } paymentMethod = value9.paymentMethod; error = value9.error; if (error != null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } if (paymentMethod == null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } return paymentMethod.id; } var EPS = env2_11.EPS; if (EPS !== type) { binding = env2_1; binding(env2_3[9])(object2.type != null, 'unsupported payment method type'); yield value5.createPaymentMethod(object2); value9 = undefined; if (false) { return value9; } paymentMethod = value9.paymentMethod; error = value9.error; if (error != null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } if (paymentMethod == null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } return paymentMethod.id; } if (a0.bank == null) { binding = env2_0; binding2 = env2_3; BillingError = binding(binding2[13]).BillingError; UNKNOWN_PAYMENT_SOURCE = binding(binding2[13]).BillingError.ErrorCodes.UNKNOWN_PAYMENT_SOURCE; throw new BillingError('EPS missing bank information'); } object2.type = 'eps'; object2.eps = {bank: a0.bank}; env2_1(env2_3[9])(object2.type != null, 'unsupported payment method type'); } yield value5.createPaymentMethod(object2); value9 = undefined; if (false) { return value9; } paymentMethod = value9.paymentMethod; error = value9.error; if (error != null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } if (paymentMethod == null) { binding = env2_0; BillingError = binding(env2_3[13]).BillingError; value11 = 'Unable to create payment source token: code: ' + (error == null ? value3 : error.code) + ' message: ' + (error == null ? value3 : error.message); binding = env2_0; UNKNOWN = binding(env2_3[13]).BillingError.ErrorCodes.UNKNOWN; throw new BillingError(); } return paymentMethod.id; } function* _fun34750(a0, a1) { // fn#34750, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:12296, offset: 0x01061a0e, size: 193 bytes, params: 3, frame: 14 let value = undefined; if (false) { return value; } if (a0 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('redirect url cannot be null on a redirect for adyen.'); } if (a1 == null) { value = environment.__proto__.__proto__; value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Payment source cannot be null on a redirect.'); } value = environment.__proto__.__proto__; const binding = env2_7; const value3 = binding.has(a1.type); const object2 = {}; if (value3) { env2_35(a0); object2.redirectConfirmation = true; object2.redirectURL = a0; } else { object2.redirectConfirmation = false; object2.redirectURL = a0; } return object2; } function* _fun34753(a0, a1) { // fn#34753, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:12738, offset: 0x01061b08, size: 397 bytes, params: 3, frame: 20 var environment; var value9; var value10; if (false) { return undefined; } value = environment.__proto__.__proto__; let binding = env2_2; const value3 = binding(env2_3[11]); const getStripe = value3.getStripe; yield Reflect.apply(getStripe, value3, []); const value4 = undefined; if (false) { return value4; } if (a1 == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Payment source cannot be null on a redirect.'); } yield getPaymentIntentInfo(a0); const value6 = undefined; if (false) { return value6; } const clientSecret = value6.clientSecret; const paymentMethodId = value6.paymentMethodId; if (value4 == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe cannot be null on a redirect.'); } if (Reflect.apply(env2_7.has, binding, [a1.type])) { binding = env2_0; value9 = binding(env2_3[6]); yield value9.popupBridgeState(a1.type); value10 = undefined; if (false) { return value10; } binding = env2_35; yield getStripeRedirect({stripe: value4, paymentSource: a1, clientSecret: clientSecret, state: value10}); value = undefined; if (false) { return value; } binding(value); return {redirectConfirmation: true}; } yield confirmPayments({stripe: value4, clientSecret: clientSecret, paymentMethodId: paymentMethodId, paymentSource: a1}); if (false) { return undefined; } return {redirectConfirmation: false}; } function* _fun34759(a0) { // fn#34759, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:13654, offset: 0x01061d28, size: 388 bytes, params: 2, frame: 20 var environment; if (false) { return undefined; } value = environment.__proto__.__proto__; const value3 = env2_2(env2_3[11]); const getStripe = value3.getStripe; yield Reflect.apply(getStripe, value3, []); const value4 = undefined; if (false) { return value4; } if (value4 == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Stripe has not loaded.'); } if (a0 == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('payment intent id cannot be null.'); } yield getClientSecret(a0); const value6 = undefined; if (false) { return value6; } yield value4.retrievePaymentIntent(value6); const value8 = undefined; if (false) { return value8; } const paymentIntent = value8.paymentIntent; const error = value8.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful stripe call'); } if (paymentIntent.last_payment_error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('unable to retrieve payment intent ' + paymentIntent.last_payment_error); } return true; } async function _fun34764({stripe, paymentSource, paymentMethodId, clientSecret}) { // fn#34764, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:14468, offset: 0x01061f26, size: 299 bytes, params: 2, frame: 19 if (true) { await undefined; if (false) { return undefined; } var type = paymentSource.type; value = environment.__proto__.__proto__; var SEPA_DEBIT = env2_11.SEPA_DEBIT; if (type !== SEPA_DEBIT) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Unsupported redirected payment source type.'); } if (paymentMethodId == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('On a sepa payment payment method id cannot be null'); } await stripe.confirmSepaDebitPayment(clientSecret, {payment_method: paymentMethodId}); if (false) { return undefined; } var paymentIntent = undefined.paymentIntent; var error = undefined.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful stripe call'); } } } async function _fun34767({stripe, paymentSource, clientSecret, state}) { // fn#34767, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:15110, offset: 0x01062093, size: 1036 bytes, params: 2, frame: 26 var r5; var binding; var object2; var billingAddress; var bank; var aPIBaseURL; var value9; var paymentIntent; var error; var next_action; if (false) { return undefined; } await undefined; if (false) { return undefined; } const type = paymentSource.type; const GIROPAY = env2_11.GIROPAY; if (GIROPAY === type) { object2 = {}; object2.billing_details = {name: paymentSource.billingAddress.name}; r5 = stripe.confirmGiropayPayment; object2 = {payment_method: object2}; binding = env2_0; aPIBaseURL = binding(env2_3[4]).getAPIBaseURL(); binding = env2_5; object2.return_url = aPIBaseURL + binding.BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX(paymentSource.type, state ?? '', 'success'); await r5(clientSecret, object2, {handleActions: false}); value9 = undefined; if (false) { return value9; } paymentIntent = value9.paymentIntent; error = value9.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful api call'); } next_action = paymentIntent.next_action; if ((next_action == null || next_action.redirect_to_url == null ? value : next_action.redirect_to_url.url) == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('confirm payment did not return a redirect url'); } next_action = paymentIntent.next_action; return next_action.redirect_to_url.url; } const BANCONTACT = env2_11.BANCONTACT; if (BANCONTACT === type) { object2 = {}; object2.billing_details = {name: paymentSource.billingAddress.name, email: paymentSource.email}; r5 = stripe.confirmBancontactPayment; object2 = {payment_method: object2}; binding = env2_0; aPIBaseURL = binding(env2_3[4]).getAPIBaseURL(); binding = env2_5; object2.return_url = aPIBaseURL + binding.BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX(paymentSource.type, state ?? '', 'success'); await r5(clientSecret, object2, {handleActions: false}); value9 = undefined; if (false) { return value9; } paymentIntent = value9.paymentIntent; error = value9.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful api call'); } next_action = paymentIntent.next_action; if ((next_action == null || next_action.redirect_to_url == null ? value : next_action.redirect_to_url.url) == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('confirm payment did not return a redirect url'); } next_action = paymentIntent.next_action; return next_action.redirect_to_url.url; } const SOFORT = env2_11.SOFORT; if (SOFORT === type) { object2 = {}; billingAddress = paymentSource.billingAddress; object2.sofort = {country: billingAddress.country}; billingAddress = paymentSource.billingAddress; object2.billing_details = {name: billingAddress.name, email: paymentSource.email}; r5 = stripe.confirmSofortPayment; object2 = {payment_method: object2}; binding = env2_0; aPIBaseURL = binding(env2_3[4]).getAPIBaseURL(); binding = env2_5; object2.return_url = aPIBaseURL + binding.BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX(paymentSource.type, state ?? '', 'success'); await r5(clientSecret, object2, {handleActions: false}); value9 = undefined; if (false) { return value9; } paymentIntent = value9.paymentIntent; error = value9.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful api call'); } next_action = paymentIntent.next_action; if ((next_action == null || next_action.redirect_to_url == null ? value : next_action.redirect_to_url.url) == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('confirm payment did not return a redirect url'); } next_action = paymentIntent.next_action; return next_action.redirect_to_url.url; } const PRZELEWY24 = env2_11.PRZELEWY24; if (PRZELEWY24 === type) { bank = paymentSource.bank; if (bank == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('PaymentSource (' + paymentSource.id + ') missing bank info for p24.'); } object2 = {}; bank = paymentSource.bank; object2.p24 = {bank: bank}; object2.billing_details = {name: paymentSource.billingAddress.name, email: paymentSource.email}; r5 = stripe.confirmP24Payment; object2 = {payment_method: object2}; binding = env2_0; aPIBaseURL = binding(env2_3[4]).getAPIBaseURL(); binding = env2_5; object2.return_url = aPIBaseURL + binding.BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX(paymentSource.type, state ?? '', 'success'); await r5(clientSecret, object2, {handleActions: false}); value9 = undefined; if (false) { return value9; } paymentIntent = value9.paymentIntent; error = value9.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful api call'); } next_action = paymentIntent.next_action; if ((next_action == null || next_action.redirect_to_url == null ? value : next_action.redirect_to_url.url) == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('confirm payment did not return a redirect url'); } next_action = paymentIntent.next_action; return next_action.redirect_to_url.url; } const EPS = env2_11.EPS; if (EPS === type) { bank = paymentSource.bank; if (bank == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('PaymentSource (' + paymentSource.id + ') missing bank info for EPS.'); } object2 = {}; bank = paymentSource.bank; object2.eps = {bank: bank}; object2.billing_details = {name: paymentSource.billingAddress.name}; r5 = stripe.confirmEpsPayment; object2 = {payment_method: object2}; binding = env2_0; aPIBaseURL = binding(env2_3[4]).getAPIBaseURL(); binding = env2_5; object2.return_url = aPIBaseURL + binding.BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX(paymentSource.type, state ?? '', 'success'); await r5(clientSecret, object2, {handleActions: false}); value9 = undefined; if (false) { return value9; } paymentIntent = value9.paymentIntent; error = value9.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful api call'); } next_action = paymentIntent.next_action; if ((next_action == null || next_action.redirect_to_url == null ? value : next_action.redirect_to_url.url) == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('confirm payment did not return a redirect url'); } next_action = paymentIntent.next_action; return next_action.redirect_to_url.url; } const IDEAL = env2_11.IDEAL; if (IDEAL === type) { object2 = {ideal: {}}; object2.billing_details = {name: paymentSource.billingAddress.name}; if (paymentSource.bank != null) { object2.ideal = {bank: paymentSource.bank}; } r5 = stripe.confirmIdealPayment; object2 = {payment_method: object2}; binding = env2_0; aPIBaseURL = binding(env2_3[4]).getAPIBaseURL(); binding = env2_5; object2.return_url = aPIBaseURL + binding.BILLING_POPUP_BRIDGE_CALLBACK_REDIRECT_PREFIX(paymentSource.type, state ?? '', 'success'); await r5(clientSecret, object2, {handleActions: false}); value9 = undefined; if (false) { return value9; } paymentIntent = value9.paymentIntent; error = value9.error; if (error != null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError(error); } if (paymentIntent == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('paymentIntent not available with successful api call'); } next_action = paymentIntent.next_action; if ((next_action == null || next_action.redirect_to_url == null ? value : next_action.redirect_to_url.url) == null) { value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('confirm payment did not return a redirect url'); } next_action = paymentIntent.next_action; return next_action.redirect_to_url.url; } value = env2_0(env2_3[6]); throw value.dispatchConfirmationError('Unsupported redirected payment source type.'); } function* _fun34771(a0) { // fn#34771, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:4957, offset: 0x0106254f, size: 154 bytes, params: 2, frame: 16 if (false) { return undefined; } if (a0 == null) { value = environment.__proto__.__proto__; throw env2_20('Stripe Elements not loaded', true); } yield a0.submit(); value = undefined; if (true) { var binding = env2_12; binding.info('Stripe Elements submit response: ', value); if (value.error != null) { binding = env2_12; binding.error('Stripe Elements submit error: ', value.error); binding = env2_20; throw binding(value.error, true); } } return value; } function* _fun34775(a0, a1) { // fn#34775, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:5343, offset: 0x01062612, size: 185 bytes, params: 3, frame: 17 var binding; if (false) { return undefined; } yield a0.createPaymentMethod({elements: a1}); value = undefined; if (false) { return value; } const paymentMethod = value.paymentMethod; const error = value.error; if (error != null) { value = environment.__proto__.__proto__; env2_12.error('Stripe createPaymentMethod error: ', error); throw env2_20(error, true); } if (paymentMethod == null) { value = environment.__proto__.__proto__; binding = env2_12; binding.warn('Stripe createPaymentMethod failed to return payment method: ', {paymentMethod: paymentMethod, error: error}); throw env2_20('paymentMethod not available with successful stripe call', true); } return {paymentMethod: paymentMethod, error: error}; } function* _fun34779(a0, a1) { // fn#34779, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:5873, offset: 0x010626f4, size: 154 bytes, params: 3, frame: 16 if (false) { return undefined; } if (a0 == null) { value = environment.__proto__.__proto__; throw env2_20('Stripe not loaded', true); } if (a1 == null) { value = environment.__proto__.__proto__; throw env2_20('Stripe Elements not loaded', true); } value = environment.__proto__.__proto__; yield env2_14(a1); if (false) { return undefined; } yield env2_15(a0, a1); value = undefined; if (false) { return value; } return {paymentMethod: value.paymentMethod, error: value.error}; } function _fun34730(a0) { // fn#34730, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:7345, offset: 0x01060d53, size: 22 bytes, params: 2, frame: 13 return env3_20(a0, true); } function _fun34734(a0) { // fn#34734, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:8231, offset: 0x01060f7f, size: 41 bytes, params: 2, frame: 11 const value = environment.__proto__.__proto__.__proto__; return env3_0(env3_3[6]).dispatchConfirmationError(a0); } function getStripeRedirect() { // fn#34755, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:13204, offset: 0x01061cb3, size: 30 bytes, params: 1, frame: 13 return env3_37.apply(this, arguments); } function confirmPayments() { // fn#34756, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4397:13373, offset: 0x01061cd1, size: 30 bytes, params: 1, frame: 13 return env3_36.apply(this, arguments); }