-
Notifications
You must be signed in to change notification settings - Fork 5k
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
fromWei
Returns "0." for 0
and Any Denomination Other Than Wei
#7339
Comments
Hi, may I work on researching and fixing this issue? It looks like a good-first-issue. Also, I'd like to ask if this kind of change would be considered a breaking change? |
@danforbes we can add check. if the result is "0." and, if so, return "0" instead. |
Hey @whitemoshui, go ahead and take a stab at this. This wouldn't be considered a breaking change. We'd like to get this implemented soon, so let us know if you have any questions. |
I saw there is a PR to fix. If he doesn't response, I can take over this issue later. |
Since #7366 appears to be inactive for weeks, I've submitted a new PR addressing the same If there are plans to continue with #7366, I'm happy to close mine. Otherwise, we could proceed with the new implementation to resolve this issue. Please let me know which approach you prefer. |
Thank you all for your contributions in resolving this bug! Your efforts are greatly appreciated! 🎉 |
When
fromWei
is called with0
and any denomination other than wei, it returns the value "0." The trailing decimal point is unnecessary and should not be included.The text was updated successfully, but these errors were encountered: