Skip to content

Commit 2c3dc6c

Browse files
committed
Let admin inherit roles
1 parent 5dd43a7 commit 2c3dc6c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/BuilderCodes.sol

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ contract BuilderCodes is
247247
///
248248
/// @return True if the address has the role
249249
function hasRole(bytes32 role, address account) public view override returns (bool) {
250-
return account == owner() || super.hasRole(role, account);
250+
return super.hasRole(role, account) || super.hasRole(getRoleAdmin(role), account) || account == owner();
251251
}
252252

253253
/// @inheritdoc ERC721Upgradeable

0 commit comments

Comments
 (0)