Beginner FriendlyFoundry
100 EXP
View results
Submission Details
Severity: low
Invalid

`PURCHASE_PRESENT_COST` is never used

Summary

Documentation specifies they want the NFT to cost 2e18, but they forgot to implement that. Right now they burn 1e18 tokens instead of 2e18.

Recommendations

//SantasList.sol
function buyPresent(address presentReceiver) external {
+ i_santaToken.burn(presentReceiver, PURCHASED_PRESENT_COST);
_mintAndIncrement();
}
//SantaToken.sol
+ function burn(address from, uint256 amount) external {
if (msg.sender != i_santasList) {
revert SantaToken__NotSantasList();
}
+ _burn(from, amount);
}
Updates

Lead Judging Commences

inallhonesty Lead Judge over 1 year ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.