diff --git a/contracts/LSP0ERC725Account/ILSP0ERC725Account.sol b/contracts/LSP0ERC725Account/ILSP0ERC725Account.sol index 8cdc2adf1..f930c39da 100644 --- a/contracts/LSP0ERC725Account/ILSP0ERC725Account.sol +++ b/contracts/LSP0ERC725Account/ILSP0ERC725Account.sol @@ -22,8 +22,8 @@ import {ILSP14Ownable2Step} from "../LSP14Ownable2Step/ILSP14Ownable2Step.sol"; */ interface ILSP0ERC725Account { /** - * @dev Emitted when receiving native tokens. * @notice `value` native tokens received from `sender`. + * @dev Emitted when receiving native tokens. * @param sender The address that sent some native tokens to this contract. * @param value The amount of native tokens received. */ diff --git a/contracts/LSP0ERC725Account/LSP0ERC725AccountCore.sol b/contracts/LSP0ERC725Account/LSP0ERC725AccountCore.sol index 1b42cdf53..133318d74 100644 --- a/contracts/LSP0ERC725Account/LSP0ERC725AccountCore.sol +++ b/contracts/LSP0ERC725Account/LSP0ERC725AccountCore.sol @@ -189,8 +189,8 @@ abstract contract LSP0ERC725AccountCore is * - If the operation type is `STATICCALL` (3) or `DELEGATECALL` (4), `value` transfer is disallowed and must be 0. * * @custom:events - * - {Executed} event for each call that uses under `operationType`: `CALL` (0), `STATICCALL` (3) and `DELEGATECALL` (4). (each iteration) - * - {ContractCreated} event, when a contract is created under `operationType`: `CREATE` (1) and `CREATE2` (2) (each iteration) + * - {Executed} event for each call that uses under `operationType`: `CALL` (0), `STATICCALL` (3) and `DELEGATECALL` (4). + * - {ContractCreated} event, when a contract is created under `operationType`: `CREATE` (1) and `CREATE2` (2). * - {ValueReceived} event when receiving native tokens. */ function execute( @@ -621,7 +621,7 @@ abstract contract LSP0ERC725AccountCore is } /** - * @notice Checking if this contract supports the interface defined by the bytes4 interface ID `interfaceId`. + * @notice Checking if this contract supports the interface defined by the `bytes4` interface ID `interfaceId`. * * @dev Achieves the goal of [ERC-165] to detect supported interfaces and [LSP-17-ContractExtension] by * checking if the interfaceId being queried is supported on another linked extension. @@ -723,15 +723,11 @@ abstract contract LSP0ERC725AccountCore is /** * @dev Forwards the call to an extension mapped to a function selector. * - * Calls {_getExtension} to get the address of the extension mapped to the function selector being - * called on the account. If there is no extension, the `address(0)` will be returned. + * Calls {_getExtension} to get the address of the extension mapped to the function selector being called on the account. If there is no extension, the `address(0)` will be returned. * - * Reverts if there is no extension for the function being called, except for the bytes4(0) function - * selector, which passes even if there is no extension for it. + * Reverts if there is no extension for the function being called, except for the bytes4(0) function selector, which passes even if there is no extension for it. * - * If there is an extension for the function selector being called, it calls the extension with the - * CALL opcode, passing the `msg.data` appended with the 20 bytes of the `msg.sender` and - * 32 bytes of the `msg.value` + * If there is an extension for the function selector being called, it calls the extension with the CALL opcode, passing the `msg.data` appended with the 20 bytes of the `msg.sender` and 32 bytes of the `msg.value` */ function _fallbackLSP17Extendable( bytes calldata callData @@ -764,9 +760,8 @@ abstract contract LSP0ERC725AccountCore is /** * @dev Returns the extension address stored under the following data key: - * {_LSP17_EXTENSION_PREFIX + } (Check [LSP2-ERC725YJSONSchema] for encoding the data key) - * - * If no extension is stored, returns the address(0) + * - {_LSP17_EXTENSION_PREFIX} + `` (Check [LSP2-ERC725YJSONSchema] for encoding the data key). + * - If no extension is stored, returns the address(0). */ function _getExtension( bytes4 functionSelector @@ -786,10 +781,10 @@ abstract contract LSP0ERC725AccountCore is } /** - * @custom:events {DataChanged} event with only the first 256 bytes of {dataValue}. - * * @dev This function overrides the {ERC725YCore} internal {_setData} function to optimize gas usage by emitting only the first 256 bytes of the `dataValue`. * + * @custom:events {DataChanged} event with only the first 256 bytes of {dataValue}. + * * @param dataKey The key to store the data value under. * @param dataValue The data value to be stored. */ diff --git a/contracts/LSP0ERC725Account/LSP0ERC725AccountInit.sol b/contracts/LSP0ERC725Account/LSP0ERC725AccountInit.sol index 41e0301f0..f73a53c77 100644 --- a/contracts/LSP0ERC725Account/LSP0ERC725AccountInit.sol +++ b/contracts/LSP0ERC725Account/LSP0ERC725AccountInit.sol @@ -24,24 +24,22 @@ import { contract LSP0ERC725AccountInit is LSP0ERC725AccountInitAbstract { /** * @notice deploying a `LSP0ERC725AccountInit` base contract to be used behind proxy - * @dev Locks the base contract on deployment, so that it cannot be initialized, owned and controlled by anyone - * after it has been deployed. This is intended so that the sole purpose of this contract is to be used as a base - * contract behind a proxy. + * @dev Locks the base contract on deployment, so that it cannot be initialized, owned and controlled by anyone after it has been deployed. This is intended so that the sole purpose of this contract is to be used as a base contract behind a proxy. */ constructor() { _disableInitializers(); } /** - * @notice Initializing the contract owner to: `initialOwner` - * @dev Set `initialOwner` as the contract owner. - * The `initialOwner` will then be allowed to call protected functions marked with the `onlyOwner` modifier. - * The `initialize(address)` function also allows funding the contract on initialization. + * @notice Initializing a LSP0ERC725Account contract with owner set to address `initialOwner`. * - * Emitted Events: - * - ValueReceived: when the contract is funded on initialization. + * @dev Set `initialOwner` as the contract owner. The `initialize(address)` also allows funding the contract on deployment. * - * @param initialOwner the owner of the contract + * @param initialOwner The owner of the contract. + * + * @custom:events + * - {ValueReceived} event when funding the contract on deployment. + * - {OwnershipTransferred} event when `initialOwner` is set as the contract {owner}. */ function initialize( address initialOwner diff --git a/contracts/LSP0ERC725Account/LSP0ERC725AccountInitAbstract.sol b/contracts/LSP0ERC725Account/LSP0ERC725AccountInitAbstract.sol index 24dc21f6f..35b7f700b 100644 --- a/contracts/LSP0ERC725Account/LSP0ERC725AccountInitAbstract.sol +++ b/contracts/LSP0ERC725Account/LSP0ERC725AccountInitAbstract.sol @@ -20,15 +20,15 @@ abstract contract LSP0ERC725AccountInitAbstract is LSP0ERC725AccountCore { /** - * @dev Set `initialOwner` as the contract owner. ERC725X & ERC725Y parent contracts - * are not initialised as they don't have non-zero initial state. - * If you decide to add non-zero initial state to any of those - * contracts, you MUST initialize them here + * @dev Set `initialOwner` as the contract owner. * - * Emitted Events: - * - ValueReceived: if the transaction that triggered this internal `_initialize` function contained some `msg.value`. + * @param initialOwner The owner of the contract. * - * @param initialOwner the owner of the contract + * @custom:warning ERC725X & ERC725Y parent contracts are not initialised as they don't have non-zero initial state. If you decide to add non-zero initial state to any of those contracts, you must initialize them here. + * + * @custom:events + * - {ValueReceived} event when funding the contract on deployment. + * - {OwnershipTransferred} event when `initialOwner` is set as the contract {owner}. */ function _initialize( address initialOwner