-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Remove ';' delimiting support from ParseDecCoins #3951
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #3951 +/- ##
===========================================
- Coverage 60.44% 60.42% -0.03%
===========================================
Files 196 196
Lines 14488 14495 +7
===========================================
+ Hits 8757 8758 +1
- Misses 5150 5157 +7
+ Partials 581 580 -1 |
} | ||
|
||
gasPricesStr := strings.Split(c.MinGasPrices, ";") | ||
gasPrices := make(sdk.DecCoins, len(gasPricesStr)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
? Wouldn't it be better to have a NewDecCoins(...)
constructor kind of thing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think so.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK.
It would be cool if we could share more logic between DecCoins
and Coins
, e.g. for parsing, but I don't know how to do it cleanly in Go. (any ideas?)
With regards to parsing, I think we can create a common function. |
closes: #3915
Targeted PR against correct branch (see CONTRIBUTING.md)
Linked to github-issue with discussion and accepted design OR link to spec that describes this work.
Wrote tests
Updated relevant documentation (
docs/
)Added a relevant changelog entry:
sdkch add [section] [stanza] [message]
rereviewed
Files changed
in the github PR explorerFor Admin Use: