"use strict";
var BraintreeError = require("../../lib/braintree-error");
module.exports = {
MASTERPASS_BROWSER_NOT_SUPPORTED: {
type: BraintreeError.types.CUSTOMER,
code: "MASTERPASS_BROWSER_NOT_SUPPORTED",
message: "Browser is not supported.",
},
MASTERPASS_NOT_ENABLED: {
type: BraintreeError.types.MERCHANT,
code: "MASTERPASS_NOT_ENABLED",
message: "Masterpass is not enabled for this merchant.",
},
MASTERPASS_TOKENIZE_MISSING_REQUIRED_OPTION: {
type: BraintreeError.types.MERCHANT,
code: "MASTERPASS_TOKENIZE_MISSING_REQUIRED_OPTION",
message: "Missing required option for tokenize.",
},
MASTERPASS_TOKENIZATION_ALREADY_IN_PROGRESS: {
type: BraintreeError.types.MERCHANT,
code: "MASTERPASS_TOKENIZATION_ALREADY_IN_PROGRESS",
message: "Masterpass tokenization is already in progress.",
},
MASTERPASS_ACCOUNT_TOKENIZATION_FAILED: {
type: BraintreeError.types.NETWORK,
code: "MASTERPASS_ACCOUNT_TOKENIZATION_FAILED",
message: "Could not tokenize user's Masterpass account.",
},
MASTERPASS_POPUP_OPEN_FAILED: {
type: BraintreeError.types.MERCHANT,
code: "MASTERPASS_POPUP_OPEN_FAILED",
message:
"Masterpass popup failed to open. Make sure to tokenize in response to a user action, such as a click.",
},
MASTERPASS_POPUP_MISSING_REQUIRED_PARAMETERS: {
type: BraintreeError.types.MERCHANT,
code: "MASTERPASS_POPUP_MISSING_REQUIRED_PARAMETERS",
message:
"Masterpass popup failed to return all required parameters needed to continue tokenization.",
},
MASTERPASS_POPUP_CLOSED: {
type: BraintreeError.types.CUSTOMER,
code: "MASTERPASS_POPUP_CLOSED",
message: "Customer closed Masterpass popup before authorizing.",
},
MASTERPASS_INVALID_PAYMENT_OPTION: {
type: BraintreeError.types.MERCHANT,
code: "MASTERPASS_INVALID_PAYMENT_OPTION",
message: "Masterpass payment options are invalid.",
},
MASTERPASS_FLOW_FAILED: {
type: BraintreeError.types.NETWORK,
code: "MASTERPASS_FLOW_FAILED",
message: "Could not initialize Masterpass flow.",
},
};