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

Vaults solution #36

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

web3gor
Copy link

@web3gor web3gor commented Jan 22, 2022

Egor G's solution for vault 1 and vault 2

@web3gor web3gor changed the title Vault 1 solution Vaults solution Jan 22, 2022
function mint (uint _amount) external payable amountGreaterThanZero(_amount){
require(msg.value == _amount, "Amount must equal the number of eth sent");
_mint(msg.sender, _amount);
emit Minted(msg.sender, _amount);
Copy link
Collaborator

Choose a reason for hiding this comment

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

function burn (uint _amount) external payable amountGreaterThanZero(_amount){
require(msg.value == _amount, "Amount must equal the number of tokens sent");
_burn(msg.sender,_amount);
emit Burned(msg.sender, _amount);
Copy link
Collaborator

Choose a reason for hiding this comment

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

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.

3 participants