Skip to content

Commit 18a34e1

Browse files
S-426 Correct natspec documentation (#78)
1 parent 17931b8 commit 18a34e1

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

src/interfaces/ITrailsRouter.sol

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ interface ITrailsRouter is IDelegatedExtension {
4242
/// @return returnResults The result of the execution.
4343
function execute(bytes calldata data) external payable returns (IMulticall3.Result[] memory returnResults);
4444

45-
/// @notice Pull ERC20 from msg.sender, then delegatecall into Multicall3.
46-
/// @dev Requires prior approval to this router.
45+
/// @notice Pull tokens from msg.sender, then delegatecall into Multicall3.
46+
/// @dev For ERC20: pulls entire balance and requires prior approval. For ETH: uses msg.value.
4747
/// @param token The ERC20 token to pull, or address(0) for ETH.
4848
/// @param data The calldata for Multicall3.
4949
/// @return returnResults The result of the execution.
@@ -52,8 +52,8 @@ interface ITrailsRouter is IDelegatedExtension {
5252
payable
5353
returns (IMulticall3.Result[] memory returnResults);
5454

55-
/// @notice Pull specific amount of ERC20 from msg.sender, then delegatecall into Multicall3.
56-
/// @dev Requires prior approval to this router.
55+
/// @notice Pull specific amount of tokens from msg.sender, then delegatecall into Multicall3.
56+
/// @dev For ERC20: requires prior approval. For ETH: requires msg.value.
5757
/// @param token The ERC20 token to pull, or address(0) for ETH.
5858
/// @param amount The amount to pull.
5959
/// @param data The calldata for Multicall3.
@@ -68,7 +68,7 @@ interface ITrailsRouter is IDelegatedExtension {
6868
// ---------------------------------------------------------------------
6969

7070
/// @notice Sweeps tokens from msg.sender and calls target with modified calldata.
71-
/// @dev For regular calls (not delegatecall). Transfers tokens from msg.sender to this contract first.
71+
/// @dev Transfers tokens from msg.sender to this contract first.
7272
/// @param token The ERC-20 token to sweep, or address(0) for ETH.
7373
/// @param target The address to call with modified calldata.
7474
/// @param callData The original calldata (must include a 32-byte placeholder).
@@ -83,7 +83,6 @@ interface ITrailsRouter is IDelegatedExtension {
8383
) external payable;
8484

8585
/// @notice Injects balance and calls target (for delegatecall context).
86-
/// @dev For delegatecalls from Sequence wallets. Reads balance from address(this).
8786
/// @param token The ERC-20 token to sweep, or address(0) for ETH.
8887
/// @param target The address to call with modified calldata.
8988
/// @param callData The original calldata (must include a 32-byte placeholder).
@@ -108,8 +107,8 @@ interface ITrailsRouter is IDelegatedExtension {
108107
// Sweeper
109108
// ---------------------------------------------------------------------
110109

111-
/// @notice Approves the sweeper if ERC20, then sweeps the entire balance to recipient.
112-
/// @dev For delegatecall context. Approval is set for `SELF` on the wallet.
110+
/// @notice Sweeps the entire balance to recipient.
111+
/// @dev For delegatecall context. Transfers all tokens/ETH held by the wallet to the recipient.
113112
/// @param token The address of the token to sweep. Use address(0) for the native token.
114113
/// @param recipient The address to send the swept tokens to.
115114
function sweep(address token, address recipient) external payable;

0 commit comments

Comments
 (0)