@exodus/fiat-balances 10.7.1 → 10.8.1

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,18 @@
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
+ ## [10.8.1](https://github.com/ExodusMovement/exodus-hydra/compare/@exodus/fiat-balances@10.8.0...@exodus/fiat-balances@10.8.1) (2024-05-13)
7
+
8
+ ### Bug Fixes
9
+
10
+ - params order ([#6920](https://github.com/ExodusMovement/exodus-hydra/issues/6920)) ([7850d94](https://github.com/ExodusMovement/exodus-hydra/commit/7850d949d1aac1e1513aab72744dea5e9bb599cd))
11
+
12
+ ## [10.8.0](https://github.com/ExodusMovement/exodus-hydra/compare/@exodus/fiat-balances@10.7.1...@exodus/fiat-balances@10.8.0) (2024-05-13)
13
+
14
+ ### Features
15
+
16
+ - make trustedUnverifiedTokens and removedTokens optional ([#6904](https://github.com/ExodusMovement/exodus-hydra/issues/6904)) ([f057013](https://github.com/ExodusMovement/exodus-hydra/commit/f057013e1c3ea4b4ba958a358a090d24398567ef))
17
+
6
18
  ## [10.7.1](https://github.com/ExodusMovement/exodus-hydra/compare/@exodus/fiat-balances@10.7.0...@exodus/fiat-balances@10.7.1) (2024-05-03)
7
19
 
8
20
  ### Bug Fixes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@exodus/fiat-balances",
3
- "version": "10.7.1",
3
+ "version": "10.8.1",
4
4
  "description": "Track asset and portfolio fiat balances based on changes in crypto balances and the user's preferred fiat currency",
5
5
  "author": "Exodus Movement, Inc.",
6
6
  "license": "UNLICENSED",
@@ -44,11 +44,11 @@
44
44
  "@exodus/assets": "^9.1.0",
45
45
  "@exodus/assets-base": "^8.1.17",
46
46
  "@exodus/assets-feature": "^5.3.1",
47
- "@exodus/available-assets": "^8.1.0",
47
+ "@exodus/available-assets": "^8.2.0",
48
48
  "@exodus/balances": "^13.1.2",
49
49
  "@exodus/blockchain-metadata": "*",
50
50
  "@exodus/combined-assets-meta": "^1.3.0",
51
- "@exodus/enabled-assets": "^10.3.0",
51
+ "@exodus/enabled-assets": "^10.3.1",
52
52
  "@exodus/favorite-assets": "^2.4.1",
53
53
  "@exodus/models": "^8.9.0",
54
54
  "@exodus/rates-monitor": "^4.2.0",
@@ -59,5 +59,5 @@
59
59
  "events": "^3.3.0",
60
60
  "redux": "^4.2.1"
61
61
  },
62
- "gitHead": "6a35a8f527d9e4f0a1ac2474e48548c274e8a38a"
62
+ "gitHead": "da5c15bd48cdb31523ab9c2ca56977db5d2af86b"
63
63
  }
@@ -1,6 +1,6 @@
1
1
  import { getCreateConversion } from '../../shared/get-create-conversion.js'
2
2
 
3
- const resultFunction = (fiatCurrency, rates, assets) => (assetName) =>
3
+ const resultFunction = (fiatCurrency, assets, rates) => (assetName) =>
4
4
  getCreateConversion(fiatCurrency, rates)(assets[assetName])
5
5
 
6
6
  const createConversionSelectorDefinition = {
@@ -2,6 +2,7 @@ import { createSelector } from 'reselect'
2
2
  import { isMultiNetworkAsset } from '../utils'
3
3
  import { groupBy } from 'lodash'
4
4
 
5
+ const EMPTY = Object.freeze([])
5
6
  const selectorFactory =
6
7
  (getIsEnabledAssetSelector, getIsUnverifiedTokenSelector, removedTokensSelector) =>
7
8
  ({ assetsListSelector }) =>
@@ -10,7 +11,12 @@ const selectorFactory =
10
11
  getIsEnabledAssetSelector,
11
12
  removedTokensSelector,
12
13
  getIsUnverifiedTokenSelector,
13
- (sortedAssetsWithBalance, getIsAssetEnabled, removedTokens, isUnverifiedCustomToken) => {
14
+ (
15
+ sortedAssetsWithBalance,
16
+ getIsAssetEnabled,
17
+ removedTokens = EMPTY,
18
+ getIsUnverifiedCustomToken
19
+ ) => {
14
20
  const assetsByNetwork = groupBy(sortedAssetsWithBalance, 'baseAsset.name')
15
21
 
16
22
  return (
@@ -25,7 +31,9 @@ const selectorFactory =
25
31
  assetsByNetwork[asset.baseAsset.name].some((asset) => getIsAssetEnabled(asset))
26
32
 
27
33
  const unverifiedCustomTokenRule =
28
- isUnverifiedCustomToken(asset) && getIsSomeNetworkAssetEnabled()
34
+ getIsUnverifiedCustomToken &&
35
+ getIsUnverifiedCustomToken(asset) &&
36
+ getIsSomeNetworkAssetEnabled()
29
37
 
30
38
  const multiNetworkAssetRule =
31
39
  isMultiNetworkAsset(asset) &&
@@ -62,8 +70,8 @@ const createEnabledAssetsWithBalanceSelectorDefinition = {
62
70
  dependencies: [
63
71
  //
64
72
  { module: 'enabledAssets', selector: 'getIsEnabled' },
65
- { module: 'trustedUnverifiedTokens', selector: 'getIsUnverified' },
66
- { module: 'removedTokens', selector: 'data' },
73
+ { module: 'trustedUnverifiedTokens', selector: 'getIsUnverified', optional: true },
74
+ { module: 'removedTokens', selector: 'data', optional: true },
67
75
  ],
68
76
  }
69
77