diff --git a/contracts/MsgValueSimulator.sol b/contracts/MsgValueSimulator.sol index 07ed23d..0f0dfe6 100644 --- a/contracts/MsgValueSimulator.sol +++ b/contracts/MsgValueSimulator.sol @@ -32,6 +32,10 @@ contract MsgValueSimulator is ISystemContract { to = address(uint160(addressAsUint)); } + /// @notice The fallback function that is the main entry point for the MsgValueSimulator. + /// @dev The contract accepts value, the callee and whether the call should a system one via its ABI params. + /// @param _data The calldata to be passed to the callee. + /// @return The return data from the callee. fallback(bytes calldata _data) external onlySystemCall returns (bytes memory) { (uint256 value, bool isSystemCall, address to) = _getAbiParams(); diff --git a/contracts/NonceHolder.sol b/contracts/NonceHolder.sol index b2775f1..7690f36 100644 --- a/contracts/NonceHolder.sol +++ b/contracts/NonceHolder.sol @@ -147,6 +147,10 @@ contract NonceHolder is INonceHolder, ISystemContract { (prevDeploymentNonce, ) = _splitRawNonce(oldRawNonce); } + /// @notice A method that checks whether the nonce has been used before. + /// @param _address The address the nonce of which is being checked. + /// @param _nonce The nonce value which is check. + /// @return `true` if the nonce has been used, `false` otherwise. function isNonceUsed(address _address, uint256 _nonce) public view returns (bool) { uint256 addressAsKey = uint256(uint160(_address)); return (_nonce < getMinNonce(_address) || nonceValues[addressAsKey][_nonce] > 0);