New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@exodus/models

Package Overview
Dependencies
Maintainers
0
Versions
136
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@exodus/models - npm Package Compare versions

Comparing version 8.5.10 to 8.5.11

4

CHANGELOG.md

@@ -0,1 +1,5 @@

## 8.5.11 / 2021-05-14
- Feat: add wallet custodial flag and ftx support
## 8.5.10 / 2021-04-28

@@ -2,0 +6,0 @@

30

lib/wallet-account/index.js

@@ -6,3 +6,3 @@ "use strict";

});
exports.default = exports.getDefaultLabel = exports.LABEL_MAX_LENGTH = exports.DEFAULT_ICONS = exports.DEFAULT_COLORS = exports.LEDGER_SRC = exports.TREZOR_SRC = exports.EXODUS_SRC = void 0;
exports.default = exports.getDefaultLabel = exports.LABEL_MAX_LENGTH = exports.DEFAULT_ICONS = exports.DEFAULT_COLORS = exports.HARDWARE_SOURCES = exports.CUSTODIAL_SOURCES = exports.FTX_SRC = exports.LEDGER_SRC = exports.TREZOR_SRC = exports.EXODUS_SRC = void 0;

@@ -23,6 +23,13 @@ var _proxyFreeze = _interopRequireDefault(require("proxy-freeze"));

exports.LEDGER_SRC = LEDGER_SRC;
const FTX_SRC = 'ftx';
exports.FTX_SRC = FTX_SRC;
const CUSTODIAL_SOURCES = [FTX_SRC];
exports.CUSTODIAL_SOURCES = CUSTODIAL_SOURCES;
const HARDWARE_SOURCES = [TREZOR_SRC, LEDGER_SRC];
exports.HARDWARE_SOURCES = HARDWARE_SOURCES;
const DEFAULT_COLORS = Object.freeze({
exodus: '#ff3974',
trezor: '#7b39ff',
ledger: '#f5e400'
ledger: '#f5e400',
ftx: '#00b4c2'
});

@@ -33,3 +40,4 @@ exports.DEFAULT_COLORS = DEFAULT_COLORS;

trezor: 'trezor',
ledger: 'trezor'
ledger: 'trezor',
ftx: 'ftx'
});

@@ -86,5 +94,7 @@ exports.DEFAULT_ICONS = DEFAULT_ICONS;

const isCustodial = CUSTODIAL_SOURCES.includes(source);
if (!source) {
throw new Error('expected "source" for a wallet account');
} else if (index == null) {
} else if (index == null && !isCustodial) {
throw new Error('expected "index" for a wallet account');

@@ -125,3 +135,3 @@ } else if (source === EXODUS_SRC && id) {

this.source = source;
this.index = index;
this.index = (0, _lodash.isNil)(index) ? null : index;
this.id = id;

@@ -180,5 +190,9 @@ this.label = label || '';

get isHardware() {
return [TREZOR_SRC, LEDGER_SRC].includes(this.source);
return HARDWARE_SOURCES.includes(this.source);
}
get isCustodial() {
return CUSTODIAL_SOURCES.includes(this.source);
}
static get DEFAULT_NAME() {

@@ -209,2 +223,4 @@ return WalletAccount.DEFAULT.toString();

_defineProperty(WalletAccount, "LEDGER_SRC", LEDGER_SRC);
_defineProperty(WalletAccount, "LEDGER_SRC", LEDGER_SRC);
_defineProperty(WalletAccount, "FTX_SRC", FTX_SRC);
{
"name": "@exodus/models",
"version": "8.5.10",
"version": "8.5.11",
"description": "Exodus models",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc