@sky-mavis/tanto-widget
Version:
Tanto Widget
22 lines (19 loc) • 609 B
JavaScript
;
class TantoWidgetError extends Error {
code;
details;
constructor(code, message, details) {
super(`[${code}] ${message}`);
this.code = code;
this.details = details;
this.name = 'TantoWidgetError';
}
}
const TantoWidgetErrorCodes = {
CLIENT_ID_REQUIRED: 'CLIENT_ID_REQUIRED',
KEYLESS_WALLET_CONFIG_MISSING_CLIENT_ID: 'KEYLESS_WALLET_CONFIG_MISSING_CLIENT_ID',
CREATE_ACCOUNT_FAILED: 'CREATE_ACCOUNT_FAILED',
CONTEXT_NOT_INITIALIZED: 'CONTEXT_NOT_INITIALIZED'
};
exports.TantoWidgetError = TantoWidgetError;
exports.TantoWidgetErrorCodes = TantoWidgetErrorCodes;