Skip to content

Commit

Permalink
docs: Natspec fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
CJ42 committed Nov 29, 2024
1 parent 04d4313 commit fe23d2d
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 26 deletions.
2 changes: 1 addition & 1 deletion packages/lsp7-contracts/contracts/LSP7DigitalAsset.sol
Original file line number Diff line number Diff line change
Expand Up @@ -758,7 +758,7 @@ abstract contract LSP7DigitalAsset is
}

/**
* @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from`
* @dev Transfers `amount` of tokens from `from` to `to`, or alternatively mints (or burns) if `from`
* (or `to`) is the zero address. All customizations to transfers, mints, and burns should be done by overriding
* this function.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ abstract contract LSP7DigitalAssetInitAbstract is
*
* 2. If the data sent to this function is of length less than 4 bytes (not a function selector), revert.
*/
// solhint-disable no-complex-fallback
// solhint-disable-next-line no-complex-fallback
fallback(
bytes calldata callData
) external payable virtual returns (bytes memory) {
Expand Down Expand Up @@ -772,11 +772,11 @@ abstract contract LSP7DigitalAssetInitAbstract is
}

/**
* @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from`
* @dev Transfers `amount` of tokens from `from` to `to`, or alternatively mints (or burns) if `from`
* (or `to`) is the zero address. All customizations to transfers, mints, and burns should be done by overriding
* this function.
*
* Emits a {Transfer} event.
* @custom:events {Transfer} event.
*/
function _update(
address from,
Expand Down
22 changes: 11 additions & 11 deletions packages/lsp7-contracts/contracts/extensions/LSP7Votes.sol
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ abstract contract LSP7Votes is LSP7DigitalAsset, EIP712, IERC5805 {
/**
* @dev Retrieve the number of votes for `account` at the end of `timepoint`.
*
* @custom:requirement
* @custom:requirements
* - `timepoint` must be in the past
*/
function getPastVotes(
Expand All @@ -121,7 +121,7 @@ abstract contract LSP7Votes is LSP7DigitalAsset, EIP712, IERC5805 {
* @dev Retrieve the `totalSupply` at the end of `timepoint`. Note, this value is the sum of all balances.
* It is NOT the sum of all the delegated votes!
*
* @custom:requirement
* @custom:requirements
* - `timepoint` must be in the past
*/
function getPastTotalSupply(
Expand Down Expand Up @@ -240,9 +240,9 @@ abstract contract LSP7Votes is LSP7DigitalAsset, EIP712, IERC5805 {
/**
* @dev Move voting power when tokens are transferred.
*
* @custom:event
* - {IVotes-DelegateVotesChanged} when voting power is removed from source address
* - {IVotes-DelegateVotesChanged} when voting power is added to destination address
* @custom:events
* - {DelegateVotesChanged} when voting power is removed from source address
* - {DelegateVotesChanged} when voting power is added to destination address
*/
function _update(
address from,
Expand All @@ -266,9 +266,9 @@ abstract contract LSP7Votes is LSP7DigitalAsset, EIP712, IERC5805 {
/**
* @dev Change delegation for `delegator` to `delegatee`.
*
* @custom:event
* - {IVotes-DelegateChanged}
* - {IVotes-DelegateVotesChanged}
* @custom:events
* - {DelegateChanged}
* - {DelegateVotesChanged}
*/
function _delegate(address delegator, address delegatee) internal virtual {
address currentDelegate = delegates(delegator);
Expand Down Expand Up @@ -312,9 +312,9 @@ abstract contract LSP7Votes is LSP7DigitalAsset, EIP712, IERC5805 {
/**
* @dev Moves voting power from one address to another.
*
* @custom:event
* - {IVotes-DelegateVotesChanged} when voting power is removed from source address
* - {IVotes-DelegateVotesChanged} when voting power is added to destination address
* @custom:events
* - {DelegateVotesChanged} when voting power is removed from source address.
* - {DelegateVotesChanged} when voting power is added to destination address
*/
function _moveVotingPower(
address src,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ abstract contract LSP7VotesInitAbstract is
/**
* @dev Retrieve the number of votes for `account` at the end of `timepoint`.
*
* @custom:requirement
* @custom:requirements
* - `timepoint` must be in the past
*/
function getPastVotes(
Expand All @@ -148,7 +148,7 @@ abstract contract LSP7VotesInitAbstract is
* @dev Retrieve the `totalSupply` at the end of `timepoint`. Note, this value is the sum of all balances.
* It is NOT the sum of all the delegated votes!
*
* @custom:requirement
* @custom:requirements
* - `timepoint` must be in the past
*/
function getPastTotalSupply(
Expand Down Expand Up @@ -267,9 +267,9 @@ abstract contract LSP7VotesInitAbstract is
/**
* @dev Move voting power when tokens are transferred.
*
* @custom:event
* - {IVotes-DelegateVotesChanged} when voting power is removed from source address
* - {IVotes-DelegateVotesChanged} when voting power is added to destination address
* @custom:events
* - {DelegateVotesChanged} when voting power is removed from source address
* - {DelegateVotesChanged} when voting power is added to destination address
*/
function _update(
address from,
Expand All @@ -293,9 +293,9 @@ abstract contract LSP7VotesInitAbstract is
/**
* @dev Change delegation for `delegator` to `delegatee`.
*
* @custom:event
* - {IVotes-DelegateChanged}
* - {IVotes-DelegateVotesChanged}
* @custom:events
* - {DelegateChanged}
* - {DelegateVotesChanged}
*/
function _delegate(address delegator, address delegatee) internal virtual {
address currentDelegate = delegates(delegator);
Expand Down Expand Up @@ -339,9 +339,9 @@ abstract contract LSP7VotesInitAbstract is
/**
* @dev Moves voting power from one address to another.
*
* @custom:event
* - {IVotes-DelegateVotesChanged} when voting power is removed from source address
* - {IVotes-DelegateVotesChanged} when voting power is added to destination address
* @custom:events
* - {DelegateVotesChanged} when voting power is removed from source address
* - {DelegateVotesChanged} when voting power is added to destination address
*/
function _moveVotingPower(
address src,
Expand Down

0 comments on commit fe23d2d

Please sign in to comment.