Skip to content

Commit 78f35d4

Browse files
committed
fix: added require in eject
1 parent 9880a8d commit 78f35d4

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/ServiceManagerBase.sol

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -163,13 +163,13 @@ abstract contract ServiceManagerBase is OwnableUpgradeable, ServiceManagerBaseSt
163163
operatorSetId < _registryCoordinator.quorumCount(),
164164
"ServiceManagerBase.ejectNonmigratedOperators: operatorSet does not exist"
165165
);
166-
IOperatorSetManager.OperatorSet memory operatorSet = IOperatorSetManager.OperatorSet({
167-
avs: address(this),
168-
id: operatorSetId
169-
});
166+
IOperatorSetManager.OperatorSet memory operatorSet =
167+
IOperatorSetManager.OperatorSet({avs: address(this), id: operatorSetId});
170168
for (uint256 i = 0; i < operators.length; ++i) {
171169
require(
172-
!_operatorSetManager.isOperatorInOperatorSet(operators[i], operatorSet),
170+
_operatorSetManager.avsOperatorStatus(address(this), operator)
171+
== IOperatorSetManager.OperatorAVSRegistrationStatus.REGISTERED
172+
&& !_operatorSetManager.isOperatorInOperatorSet(operators[i], operatorSet),
173173
"ServiceManagerBase.removeNonmigratedOperators: operator already registered to operator set"
174174
);
175175
bytes32 operatorId = _registryCoordinator.getOperatorId(operators[i]);

0 commit comments

Comments
 (0)