@rnw-community/react-native-payments
Version:
Accept Payments with Apple Pay and Android Pay using the Payment Request API.
8 lines • 498 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.isNativeUserCancellation = void 0;
const shared_1 = require("@rnw-community/shared");
const nativeCancellationCodes = new Set(['E_CANCELLED_BY_USER', 'payment_error']);
const isNativeUserCancellation = (error) => (0, shared_1.isError)(error) && nativeCancellationCodes.has(error.code ?? '');
exports.isNativeUserCancellation = isNativeUserCancellation;
//# sourceMappingURL=is-native-user-cancellation.util.js.map