F-2025-0022·code-quality

Unused custom error in FeeDistributionVault reduces code clarity and increases gas costs

Fixedliquid-stakinglststaking-poolsgithub.com/matchain/contracts
TL;DR

FeeDistributionVault declares a TransferFailed() custom error on line 49 that is never referenced. The contract uses SafeERC20 which reverts with its own messages, so this error is dead code.

Severity
INFO
Impact
LOW
Likelihood
LOW
Method
MManual review
CAT.
Complexity
LOW
Exploitability
LOW
02Section · Description

Description

The FeeDistributionVault contract defines a custom error TransferFailed() on line 49, but this error is never used anywhere in the contract implementation.

The contract uses OpenZeppelin's SafeERC20 library for token transfers, which handles transfer failures internally by reverting with its own error messages.

03Section · Impact

Impact

Dead code increases bytecode size and reduces clarity. No runtime impact.

04Section · Recommendation

Recommendation

Remove the unused TransferFailed error from the contract to improve code clarity and reduce bytecode size.

F-2025-0022

oog
zealynx

Smart Contract Security Digest

Monthly exploit breakdowns, audit checklists, and DeFi security research — straight to your inbox

© 2026 Zealynx