Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

exclude fields from token list fetch #4235

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

bergeron
Copy link
Contributor

@bergeron bergeron commented Apr 30, 2024

Explanation

Adds 2 query parameters when fetching token lists:

  • includeERC20Permit=false
  • includeStorage=false

The best I can tell, neither field is used by extension or mobile. So we'll instead take the reduction in network usage (~5KB on mainnet) and controller state.

References

https://consensyssoftware.atlassian.net/browse/API-1186

Changelog

@metamask/assets-controllers

  • BREAKING: TokenListController no longer includes the fields storage and erc20Permit in its state.

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've highlighted breaking changes using the "BREAKING" category above as appropriate

@bergeron bergeron requested a review from a team as a code owner April 30, 2024 19:49
hurricanenara
hurricanenara previously approved these changes Apr 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants