Raisebox Faucet

First Flight #50
Beginner FriendlySolidity
100 EXP
View results
Submission Details
Impact: low
Likelihood: low
Invalid

Unused state variable and error definition increase deployment costs and code complexity

Description:

The contract contains two unused declarations that serve no functional purpose:

1. Unused state variable blockTime:

uint256 public blockTime = block.timestamp;

2. Unused custom error RaiseBoxFaucet_CannotClaimAnymoreFaucetToday:

error RaiseBoxFaucet_CannotClaimAnymoreFaucetToday();

Both declarations suggest either:

  • Incomplete refactoring where old code wasn't cleaned up

  • Abandoned features that were never fully implemented

  • Planning for future functionality that was never added

Impact:

Gas costs:

  • The blockTime state variable permanently consumes a storage slot (20,000 gas at deployment)

  • Increases total deployment cost unnecessarily

Code maintainability:

  • Makes the codebase appear less professionally maintained


Recommended Mitigation:

Remove both unused declarations from the contract

Updates

Lead Judging Commences

inallhonesty Lead Judge 13 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.