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

Feature: EIP747 watchAsset #84

Merged
merged 4 commits into from
Apr 3, 2019
Merged

Feature: EIP747 watchAsset #84

merged 4 commits into from
Apr 3, 2019

Conversation

estebanmino
Copy link
Contributor

This PR adds support to handle EIP747 from AssetsController and was mostly inspired mostly on how we handle transactions in TransactionController.
For now these methods only support Tokens, but was meant to easily add new types of assets in the future.

Copy link
Contributor

@brunobar79 brunobar79 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great. Good stuff Esteban

const releaseLock = await this.mutex.acquire();
address = toChecksumAddress(address);
const { allTokens, tokens } = this.state;
const { networkType, selectedAddress } = this.config;
const newEntry: Token = { address, symbol, decimals };
const newEntry: Token = { address, symbol, decimals, image };
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just making sure that the state generated before this PR doesn’t break due to the new image property being added

Copy link
Contributor

@bitpshr bitpshr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great.

@estebanmino estebanmino merged commit 7c312ee into master Apr 3, 2019
@whymarrh whymarrh deleted the feature/watch-asset branch November 5, 2019 17:43
mcmire pushed a commit to mcmire/core that referenced this pull request Jul 17, 2023
MajorLift pushed a commit that referenced this pull request Oct 11, 2023
* allow token image

* watch accept and reject asset

* update doc

* tests
MajorLift pushed a commit that referenced this pull request Oct 11, 2023
* allow token image

* watch accept and reject asset

* update doc

* tests
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.

3 participants