The setGameContract function allows the contract owner to change the gameContract state variable, which designates the only address permitted to mint new Egg NFTs. However, this function does not emit an event upon successful execution.
State-changing functions, especially those modifying critical authorization parameters like the designated minter address, should emit events. This allows off-chain monitoring tools, user interfaces, and other interested parties to track changes in the contract's state and configuration efficiently. The setGameContract function updates the gameContract variable but lacks an accompanying event emission.
The absence of an event makes it difficult for external systems and users to track changes to the authorized minter address. This lack of transparency can hinder monitoring efforts and potentially cause issues for applications or users relying on knowing the currently authorized game contract, as they might operate based on outdated information.
Manual Review
Emit an event within the setGameContract function to signal the change in the authorized minter address.
Define a new event, for example:
Emit this event within the setGameContract function after the update:
Standard practice for clarifying important contract behaviors
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.