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

Missing Event Emission in collectPresent Function

Summary

The collectPresent function in the SantasList contract is designed to mint tokens to users based on certain conditions. However, it currently lacks an event emission upon successful token minting. Any time state changes within a contract the function should emit and event.

Vulnerability Details

It is challenging to to track when tokens have been minted and by whom

Impact

A transaction invoking collectPresent can be executed, and the transaction receipt inspected. While the function executes as intended (minting tokens), the receipt lacks an event log corresponding to this action. This absence of logging is not in line with standard practices for smart contract development, where significant state changes are typically accompanied by event emissions.

Tools Used

Manual

Recommendations

Implement Event Logging

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.