RebateFi Hook

First Flight #53
Beginner FriendlyDeFi
100 EXP
View results
Submission Details
Impact: low
Likelihood: low
Invalid

Missing Event Emission in `ChangeFee`

Description:
The ChangeFee function allows the owner to modify critical protocol parameters (buyFee and sellFee) but does not emit any events to signal these state changes. This makes it impossible for off-chain monitoring systems, indexers, and frontend applications to track fee modifications in real-time.

Impact:
Lack of event emission reduces protocol transparency and makes it difficult for users and monitoring tools to detect fee changes. Off-chain systems must continuously poll contract state to detect changes, which is inefficient and may cause delayed reactions to fee updates.

Mitigation:

+ event FeeChanged(uint24 indexed newBuyFee, uint24 indexed newSellFee);
function ChangeFee(
bool _isBuyFee,
uint24 _buyFee,
bool _isSellFee,
uint24 _sellFee
) external onlyOwner {
if(_isBuyFee) buyFee = _buyFee;
if(_isSellFee) sellFee = _sellFee;
+ emit FeeChanged(buyFee, sellFee);
}
Updates

Lead Judging Commences

chaossr Lead Judge 12 days ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

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

Give us feedback!