@chain-registry/utils 1.6.0 → 1.8.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.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,22 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [1.8.0](https://github.com/cosmology-tech/chain-registry/compare/@chain-registry/utils@1.7.0...@chain-registry/utils@1.8.0) (2023-03-29)
7
+
8
+ **Note:** Version bump only for package @chain-registry/utils
9
+
10
+
11
+
12
+
13
+
14
+ # [1.7.0](https://github.com/cosmology-tech/chain-registry/compare/@chain-registry/utils@1.6.0...@chain-registry/utils@1.7.0) (2023-03-02)
15
+
16
+ **Note:** Version bump only for package @chain-registry/utils
17
+
18
+
19
+
20
+
21
+
6
22
  # [1.6.0](https://github.com/cosmology-tech/chain-registry/compare/@chain-registry/utils@1.5.0...@chain-registry/utils@1.6.0) (2023-02-23)
7
23
 
8
24
  **Note:** Version bump only for package @chain-registry/utils
package/main/utils.js CHANGED
@@ -150,13 +150,26 @@ var getIbcAssets = function getIbcAssets(chainName, ibc, assets) {
150
150
  var counterparty = ibcInfo[counterpartyIs].chain_name;
151
151
  var counterpartyIbc = ibcInfo[counterpartyIs];
152
152
  var chainIbc = ibcInfo[chainIs];
153
- var counterpartyAssets = assets.find(function (a) {
153
+ var baseCounterpartyAssets = assets.find(function (a) {
154
154
  return a.chain_name === counterparty;
155
155
  });
156
- if (!counterpartyAssets) {
156
+ if (!baseCounterpartyAssets) {
157
157
  // console.warn('asset not found: ' + counterparty);
158
158
  return;
159
159
  }
160
+
161
+ // const counterpartyAssets = baseCounterpartyAssets;
162
+ var counterpartyAssets = _objectSpread(_objectSpread({}, baseCounterpartyAssets), {}, {
163
+ assets: baseCounterpartyAssets.assets.filter(function (a) {
164
+ if (
165
+ // https://github.com/cosmos/chain-registry/issues/1535
166
+ baseCounterpartyAssets.chain_name === 'carbon' && a.base.startsWith('ibc/')) {
167
+ return false;
168
+ } else {
169
+ return true;
170
+ }
171
+ })
172
+ });
160
173
  var ibcAssets = counterpartyAssets.assets.filter(function (a) {
161
174
  return !a.base.startsWith('cw20:');
162
175
  }).map(function (asset) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chain-registry/utils",
3
- "version": "1.6.0",
3
+ "version": "1.8.0",
4
4
  "description": "Chain Registry Utils",
5
5
  "author": "Dan Lynch <pyramation@gmail.com>",
6
6
  "homepage": "https://github.com/cosmology-tech/chain-registry",
@@ -76,5 +76,5 @@
76
76
  "@chain-registry/types": "^0.14.0",
77
77
  "sha.js": "^2.4.11"
78
78
  },
79
- "gitHead": "8bb3d59f915d87ad452faeccda5911645b642b0e"
79
+ "gitHead": "ffcf72b1c19f90354beca294ff5224ff6577f0ea"
80
80
  }