diff --git a/src/contracts/core/AllocationManager.sol b/src/contracts/core/AllocationManager.sol index b463d8480..6d931f0a8 100644 --- a/src/contracts/core/AllocationManager.sol +++ b/src/contracts/core/AllocationManager.sol @@ -537,7 +537,7 @@ contract AllocationManager is */ /// @inheritdoc IAllocationManager - function getAVSSetCount( + function getOperatorSetCount( address avs ) external view returns (uint256) { return _operatorSets[avs].length(); diff --git a/src/contracts/core/RewardsCoordinator.sol b/src/contracts/core/RewardsCoordinator.sol index ba2165d99..2770e0a5e 100644 --- a/src/contracts/core/RewardsCoordinator.sol +++ b/src/contracts/core/RewardsCoordinator.sol @@ -228,7 +228,7 @@ contract RewardsCoordinator is /// @inheritdoc IRewardsCoordinator function setClaimerFor(address earner, address claimer) external checkCanCall(earner) { // Require that the earner is an operator or AVS - require(delegationManager.isOperator(earner) || allocationManager.getAVSSetCount(earner) > 0, InvalidEarner()); + require(delegationManager.isOperator(earner) || allocationManager.getOperatorSetCount(earner) > 0, InvalidEarner()); _setClaimer(earner, claimer); } diff --git a/src/contracts/interfaces/IAllocationManager.sol b/src/contracts/interfaces/IAllocationManager.sol index 4d1a4e290..0ebbc1699 100644 --- a/src/contracts/interfaces/IAllocationManager.sol +++ b/src/contracts/interfaces/IAllocationManager.sol @@ -334,7 +334,7 @@ interface IAllocationManager is ISignatureUtils, IAllocationManagerErrors, IAllo * @notice Returns the number of operator sets for the AVS * @param avs the AVS to query */ - function getAVSSetCount( + function getOperatorSetCount( address avs ) external view returns (uint256); diff --git a/src/test/mocks/AllocationManagerMock.sol b/src/test/mocks/AllocationManagerMock.sol index a75d53820..9ccb063a0 100644 --- a/src/test/mocks/AllocationManagerMock.sol +++ b/src/test/mocks/AllocationManagerMock.sol @@ -11,7 +11,7 @@ contract AllocationManagerMock is Test { receive() external payable {} fallback() external payable {} - mapping(address avs => uint256) public getAVSSetCount; + mapping(address avs => uint256) public getOperatorSetCount; mapping(address => mapping(IStrategy => Snapshots.DefaultWadHistory)) internal _maxMagnitudeHistory; function setMaxMagnitudes( @@ -72,6 +72,6 @@ contract AllocationManagerMock is Test { } function setAVSSetCount(address avs, uint256 numSets) external { - getAVSSetCount[avs] = numSets; + getOperatorSetCount[avs] = numSets; } } \ No newline at end of file diff --git a/src/test/unit/AllocationManagerUnit.t.sol b/src/test/unit/AllocationManagerUnit.t.sol index 96df7337e..a5572de07 100644 --- a/src/test/unit/AllocationManagerUnit.t.sol +++ b/src/test/unit/AllocationManagerUnit.t.sol @@ -3216,7 +3216,7 @@ contract AllocationManagerUnitTests_createOperatorSets is AllocationManagerUnitT } } - assertEq(createSetParams.length, allocationManager.getAVSSetCount(avs), "should be correct number of sets"); + assertEq(createSetParams.length, allocationManager.getOperatorSetCount(avs), "should be correct number of sets"); } }