Skip to content

Commit 0f85181

Browse files
bergarcesmicaelae
authored andcommitted
fix: token selector issues (#6358)
## Explanation <!-- Thanks for your contribution! Take a moment to answer these questions so that reviewers have the information they need to properly understand your changes: * What is the current state of things and why does it need to change? * What is the solution your changes offer and how does it work? * Are there any changes whose purpose might not obvious to those unfamiliar with the domain? * If your primary goal was to update one package but you found you had to update another one along the way, why did you do so? * If you had to upgrade a dependency, why did you do so? --> The format for EVM addresses for AccountTrackerController in mobile differs from extension and from the other controller states. This was causing it to miss native account balances. It also uses the correct internal account type in the assets, so that BTC account types can be identified. Finally, it fixes an issue with the `mergeAssets` function mutating internal parts of cached objects. ## References <!-- Are there any issues that this pull request is tied to? Are there other links that reviewers should consult to understand these changes better? Are there client or consumer pull requests to adopt any breaking changes? For example: * Fixes #12345 * Related to #67890 --> ## Checklist - [X] I've updated the test suite for new or updated code as appropriate - [X] I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate - [X] I've communicated my changes to consumers by [updating changelogs for packages I've changed](https://github.com/MetaMask/core/tree/main/docs/contributing.md#updating-changelogs), highlighting breaking changes as necessary - [X] I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes
1 parent fd26569 commit 0f85181

File tree

3 files changed

+238
-147
lines changed

3 files changed

+238
-147
lines changed

packages/assets-controllers/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1010
### Changed
1111

1212
- Bump `@metamask/base-controller` from `^8.1.0` to `^8.2.0` ([#6355](https://github.com/MetaMask/core/pull/6355))
13+
- Uses the correct internal account type for the asset ([#6358](https://github.com/MetaMask/core/pull/6358)).
14+
15+
### Fixed
16+
17+
- Ensure that the evm addresses used for an internal mapping are always lowercase to avoid mismatches with client format ([#6358](https://github.com/MetaMask/core/pull/6358)).
18+
- Prevents mutation of memoized fields, which was causing issues ([#6358](https://github.com/MetaMask/core/pull/6358)).
1319

1420
## [74.0.0]
1521

0 commit comments

Comments
 (0)