-
Notifications
You must be signed in to change notification settings - Fork 75
feat(documentation): Add NatSpec comments to contracts #59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
contracts/HubPool.sol
Outdated
| import "@openzeppelin/contracts/utils/Address.sol"; | ||
|
|
||
| /** | ||
| * @notice Contract deployed on Ethereum that houses L1 token liquidity for all SpokePools. Admin can instruct this |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we say "admin"? this is not really correct, no? it's more that a valid bundle does the action you describe.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, this is definitely not an admin. Anyone can propose these and their validity is validated via the OO.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure
contracts/HubPool.sol
Outdated
|
|
||
| /** | ||
| * @notice Contract deployed on Ethereum that houses L1 token liquidity for all SpokePools. Admin can instruct this | ||
| * contract to send tokens to L2 SpokePools via "pool rebalances" with which to pay out relayers on those networks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"with which to pay out relayers" is a bit clunky. can you refactor this sentence a bit?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure
contracts/HubPool.sol
Outdated
| /** | ||
| * @notice Contract deployed on Ethereum that houses L1 token liquidity for all SpokePools. Admin can instruct this | ||
| * contract to send tokens to L2 SpokePools via "pool rebalances" with which to pay out relayers on those networks. | ||
| * Admin also can publish relayer refund and slow relay merkle roots to SpokePools via this contract. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, not sure if we should use the Admin word. wdyt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure changing
contracts/HubPool.sol
Outdated
| mapping(bytes32 => address) private whitelistedRoutes; | ||
|
|
||
| // Mapping of L1TokenAddress to the associated Pool information. | ||
| // Mapping of L1 token addresses to the associated pool information. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this comment come after the struct declaration, but before the mapping is defined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure
contracts/HubPool.sol
Outdated
|
|
||
| function addLiquidity(address l1Token, uint256 l1TokenAmount) public payable { | ||
| /** | ||
| * @notice Deposit liquidity into this contract to earn LP fees in exchange for backstopping relays on SpokePools. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is backstopping the right word? I get what you're saying; it totally makes sence but is it the most correct word?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I think funding is probably a more correct word.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changed to funding
| * refund relayers. | ||
| * @param slowRelayRoot Slow relay root to publish to Spoke Pool where a data worker can execute leaves to | ||
| * fulfill slow relays. | ||
| */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you are missing a comment on poolRebalanceRoot
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
Co-authored-by: Chris Maree <christopher.maree@gmail.com>
No description provided.