Skip to content
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

Cw20 zero amount checks #86

Merged
merged 2 commits into from
Sep 14, 2020
Merged

Cw20 zero amount checks #86

merged 2 commits into from
Sep 14, 2020

Conversation

maurolacy
Copy link
Contributor

@maurolacy maurolacy commented Sep 12, 2020

Add checks for rejecting zero-amount Cw20 tokens.

Also improves the use of Cw20Coin(Human) accross contracts.

Closes the Cw20 part of #76.

@maurolacy maurolacy self-assigned this Sep 12, 2020
Copy link
Member

@ethanfrey ethanfrey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice one. I would add another safety check to cw20-base::handle_send to not send 0 tokens, but that is a different pr/issue

contracts/cw20-base/src/allowances.rs Show resolved Hide resolved
contracts/cw20-escrow/src/contract.rs Show resolved Hide resolved
@ethanfrey ethanfrey merged commit 243801c into master Sep 14, 2020
@ethanfrey ethanfrey deleted the cw20-zero-amount-checks branch September 14, 2020 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants