@cityofzion/bs-neo-legacy 1.0.4 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -48,7 +48,7 @@ class BSNeoLegacy {
48
48
  __classPrivateFieldGet(this, _BSNeoLegacy_instances, "m", _BSNeoLegacy_setTokens).call(this, network);
49
49
  this.network = network;
50
50
  this.blockchainDataService = new DoraBDSNeoLegacy_1.DoraBDSNeoLegacy(network, this.feeToken, this.claimToken, this.tokens);
51
- this.exchangeDataService = new CryptoCompareEDSNeoLegacy_1.CryptoCompareEDSNeoLegacy(network, this.tokens);
51
+ this.exchangeDataService = new CryptoCompareEDSNeoLegacy_1.CryptoCompareEDSNeoLegacy(network);
52
52
  this.explorerService = new NeoTubeESNeoLegacy_1.NeoTubeESNeoLegacy(network);
53
53
  }
54
54
  validateAddress(address) {
@@ -1,8 +1,8 @@
1
- import { CryptoCompareEDS, Currency, ExchangeDataService, GetTokenPriceHistory, Network, Token, TokenPricesHistoryResponse, TokenPricesResponse } from '@cityofzion/blockchain-service';
1
+ import { CryptoCompareEDS, ExchangeDataService, GetTokenPriceHistoryParams, GetTokenPricesParams, Network, TokenPricesHistoryResponse, TokenPricesResponse } from '@cityofzion/blockchain-service';
2
2
  import { BSNeoLegacyNetworkId } from './BSNeoLegacyHelper';
3
3
  export declare class CryptoCompareEDSNeoLegacy extends CryptoCompareEDS implements ExchangeDataService {
4
4
  #private;
5
- constructor(network: Network<BSNeoLegacyNetworkId>, tokens: Token[]);
6
- getTokenPriceHistory(params: GetTokenPriceHistory): Promise<TokenPricesHistoryResponse[]>;
7
- getTokenPrices(currency: Currency): Promise<TokenPricesResponse[]>;
5
+ constructor(network: Network<BSNeoLegacyNetworkId>);
6
+ getTokenPriceHistory(params: GetTokenPriceHistoryParams): Promise<TokenPricesHistoryResponse[]>;
7
+ getTokenPrices(params: GetTokenPricesParams): Promise<TokenPricesResponse[]>;
8
8
  }
@@ -25,8 +25,8 @@ exports.CryptoCompareEDSNeoLegacy = void 0;
25
25
  const blockchain_service_1 = require("@cityofzion/blockchain-service");
26
26
  const BSNeoLegacyHelper_1 = require("./BSNeoLegacyHelper");
27
27
  class CryptoCompareEDSNeoLegacy extends blockchain_service_1.CryptoCompareEDS {
28
- constructor(network, tokens) {
29
- super(tokens);
28
+ constructor(network) {
29
+ super();
30
30
  _CryptoCompareEDSNeoLegacy_network.set(this, void 0);
31
31
  __classPrivateFieldSet(this, _CryptoCompareEDSNeoLegacy_network, network, "f");
32
32
  }
@@ -40,14 +40,14 @@ class CryptoCompareEDSNeoLegacy extends blockchain_service_1.CryptoCompareEDS {
40
40
  return yield _super.getTokenPriceHistory.call(this, params);
41
41
  });
42
42
  }
43
- getTokenPrices(currency) {
43
+ getTokenPrices(params) {
44
44
  const _super = Object.create(null, {
45
45
  getTokenPrices: { get: () => super.getTokenPrices }
46
46
  });
47
47
  return __awaiter(this, void 0, void 0, function* () {
48
48
  if (!BSNeoLegacyHelper_1.BSNeoLegacyHelper.isMainnet(__classPrivateFieldGet(this, _CryptoCompareEDSNeoLegacy_network, "f")))
49
49
  throw new Error('Exchange is only available on mainnet');
50
- return yield _super.getTokenPrices.call(this, currency);
50
+ return yield _super.getTokenPrices.call(this, params);
51
51
  });
52
52
  }
53
53
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cityofzion/bs-neo-legacy",
3
- "version": "1.0.4",
3
+ "version": "1.1.0",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "author": "Coz",
@@ -11,7 +11,7 @@
11
11
  "dependencies": {
12
12
  "@cityofzion/dora-ts": "0.0.11",
13
13
  "@cityofzion/neon-js": "4.8.3",
14
- "@cityofzion/blockchain-service": "1.0.2",
14
+ "@cityofzion/blockchain-service": "1.1.0",
15
15
  "@cityofzion/bs-asteroid-sdk": "0.9.0"
16
16
  },
17
17
  "devDependencies": {