You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If initial_balances contains one or more duplicate accounts, these accounts will have the balance of the final balance saved to state, whilst the total_supply will be the sum over all initial balances provided.
Thank you for this report. It would be good to assert that all addresses in the initial_balances list only appear once, and fail if there are duplicates
If
initial_balances
contains one or more duplicate accounts, these accounts will have the balance of the final balance saved to state, whilst thetotal_supply
will be the sum over all initial balances provided.cw-plus/contracts/cw20-base/src/contract.rs
Lines 154 to 162 in 501efe8
Example:
Should we assert that all accounts in
initial_balances
are unique? Happy to make a PR for this if there is interest.NB this was found in an audit of Mars protocol in a contract that was forked from the cw-plus cw20-base contract.
The text was updated successfully, but these errors were encountered: