-
Notifications
You must be signed in to change notification settings - Fork 355
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
Why cw20-base do not care about minting cap? #339
Comments
12 lines below the line you linked, the cap is enforced: https://github.com/CosmWasm/cosmwasm-plus/blob/9c37cca15bd341d44e3e855f92fcf61b5a125b1e/contracts/cw20-base/src/contract.rs#L209-L215 |
@ethanfrey mmm, yes, you are right. But this cap checks |
Then the comment should be updated. My intention when writing it, is "mintable with cap" enforced a maximum supply that can be minted in the end (and if you burn some tokens, this allows you to mint more) |
I didn't know where bug is - in comment or in code. By default I think code is wrong :) |
I made an issue to close this. As I designed cw20 and wrote most of the implementations, I am pretty clear what was in my head when I wrote the spec and wrote the code which matches it. If I have tested code and it doesn't match the comments, well the tests are the best guide as to what was expected. |
I found that cw20-base contract do not use
cap
field from: https://github.com/CosmWasm/cosmwasm-plus/blob/9c37cca15bd341d44e3e855f92fcf61b5a125b1e/packages/cw20/src/query.rs#L65Why?
https://github.com/CosmWasm/cosmwasm-plus/blob/9c37cca15bd341d44e3e855f92fcf61b5a125b1e/contracts/cw20-base/src/contract.rs#L193
The text was updated successfully, but these errors were encountered: