Open code423n4 opened 2 years ago
namesLength > 0
areOperatorsImported()
true
[]
function areOperatorsImported(bytes32[] calldata names, Operator[] calldata destinations) external view override returns (bool) { uint256 namesLength = names.length; require(namesLength == destinations.length, "OR: INPUTS_LENGTH_MUST_MATCH"); for (uint256 i = 0; i < namesLength; i++) { if ( operators[names[i]].implementation != destinations[i].implementation || operators[names[i]].selector != destinations[i].selector ) { return false; } } return true; }
require(namesLength > 0 "empty names/destinations");
Add
namesLength > 0
check inareOperatorsImported()
methodareOperatorsImported()
in OperatorResolver.sol#L32-L49 returnstrue
when input arrays are empty (ie.[]
,[]
).Recommendation