Beginner FriendlyFoundryNFT
100 EXP
View results
Submission Details
Severity: low
Valid

`battlesWon` field stat is never updated

Summary

battlesWon field stat is never updated after _battle() ends

Vulnerability Details

The RapBattle smart contract should be able to update battlesWon field with OneShot contract. _battle() function is not updating battlesWon after getting results of the battle

Impact

Users will be not able to move in ranking (or smth like that)

Tools Used

Only manual review was used.

Recommendations

Consider updating onlyStreetContract modifier in the OneShot.sol to onlyStreetOrRapBattleContracts and adding RapBattle contract address to storage for checking with modifier. Or add separate modifier to the OneShot and add updating of battlesWon to the _battle() function

Updates

Lead Judging Commences

inallhonesty Lead Judge over 1 year ago
Submission Judgement Published
Validated
Assigned finding tags:

`battlesWon` is never updated

Support

FAQs

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