Skip to content

Conversation

@DhairyaSethi
Copy link
Member

No description provided.

address spoke
) external returns (uint256) {
) external restricted returns (uint256) {
Asset storage asset = _assets[assetId];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check asset is registered

) external restricted returns (uint256) {
Asset storage asset = _assets[assetId];
SpokeData storage callerSpoke = _spokes[assetId][msg.sender];
SpokeData storage coveredSpoke = _spokes[assetId][spoke];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check coveredSpoke is registered

bytes4[] memory selectors = new bytes4[](1);
selectors[0] = IHub.eliminateDeficit.selector;
manager.setTargetFunctionRole(address(targetHub), selectors, Roles.HUB_UMBRELLA_ROLE);
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you put this into a helper func, will be easier to refactor later

);

vm.prank(ADMIN);
accessManager.grantRole(Roles.HUB_UMBRELLA_ROLE, address(spoke1), 0);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you put this into a helper func too

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants