CurrencyController can be configured to always fetch usd rate#292
Merged
CurrencyController can be configured to always fetch usd rate#292
Conversation
Gudahtt
reviewed
Oct 27, 2020
Gudahtt
reviewed
Oct 27, 2020
Gudahtt
reviewed
Oct 27, 2020
…tion to currentCurrency rate
Co-authored-by: Mark Stacey <markjstacey@gmail.com>
Co-authored-by: Mark Stacey <markjstacey@gmail.com>
Co-authored-by: Mark Stacey <markjstacey@gmail.com>
Contributor
Author
|
@Gudahtt All of your suggested commits were applied (thanks!) and I have rebased this onto develop |
Merged
Contributor
Author
Contributor
Author
|
@Gudahtt The remaining test failure here also exists on develop and is unrelated to these changes. |
MajorLift
pushed a commit
that referenced
this pull request
Oct 11, 2023
* CurrencyController can be configured to always fetch usd rate in addition to currentCurrency rate * Update unit tests Co-authored-by: Mark Stacey <markjstacey@gmail.com>
MajorLift
pushed a commit
that referenced
this pull request
Oct 11, 2023
* CurrencyController can be configured to always fetch usd rate in addition to currentCurrency rate * Update unit tests Co-authored-by: Mark Stacey <markjstacey@gmail.com>
Mrtenz
pushed a commit
that referenced
this pull request
Oct 16, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
For analytics purposes in metamask-extension, we have a need of always knowing the the ETH to USD rate, even when the users selected currency is not USD. This PR updates the CurrencyController so that it can be passed a
includeUSDRateconfig property that ensures that the exchange rate forUSDis always fetched, in addition to whatever thecurrentCurrencyis.