sherlock-audit / 2024-05-beefy-cowcentrated-liquidity-manager-judging

5 stars 5 forks source link

`BeefyRewardPool` should inherit from `IRewardPool` #135

Closed sherlock-admin3 closed 2 months ago

sherlock-admin3 commented 2 months ago

BeefyRewardPool should inherit from IRewardPool

Low/Info issue submitted by ccashwell

Summary

BeefyRewardPool.sol is an implementation of the IRewardPool interface, but does not inherit the interface. Informational only.

Vulnerability Detail

The reward pool implementation does not reference the interface it intends to implement.

Impact

Low/Informational - no tangible impact

Code Snippet

IRewardPool.sol

// SPDX-License-Identifier: MIT
pragma solidity 0.8.23;

interface IRewardPool {
    function notifyRewardAmount(address token, uint256 reward, uint256 duration) external;
}

BeefyRewardPool.sol

// ...
contract BeefyRewardPool is ERC20Upgradeable, OwnableUpgradeable {
// ...
    function notifyRewardAmount(
        address _reward,
        uint256 _amount,
        uint256 _duration
    ) external onlyManager update(address(0)) {
// ...

Tool used

Manual Review

Recommendation

Implement the interface or remove it.