-
Notifications
You must be signed in to change notification settings - Fork 504
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use currency library to combine sweepETH and sweepToken
- Loading branch information
1 parent
0152e5c
commit e5fc9dd
Showing
2 changed files
with
12 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,17 @@ | ||
// SPDX-License-Identifier: UNLICENSED | ||
pragma solidity ^0.8.19; | ||
|
||
import {Currency} from "@uniswap/v4-core/contracts/types/Currency.sol"; | ||
|
||
/// @title Periphery Payments | ||
/// @notice Functions to ease deposits and withdrawals of ETH | ||
interface IPeripheryPayments { | ||
// TODO: figure out if we still need unwrapWETH9 from v3? | ||
|
||
/// @notice Refunds any ETH balance held by this contract to the `msg.sender` | ||
/// @dev Useful for bundling with mint or increase liquidity that uses ether, or exact output swaps | ||
/// that use ether for the input amount | ||
function refundETH() external payable; | ||
|
||
/// @notice Transfers the full amount of a token held by this contract to recipient | ||
/// @dev The amountMinimum parameter prevents malicious contracts from stealing the token from users | ||
/// @param token The contract address of the token which will be transferred to `recipient` | ||
/// @param currency The contract address of the token which will be transferred to `recipient` | ||
/// @param amountMinimum The minimum amount of token required for a transfer | ||
/// @param recipient The destination address of the token | ||
function sweepToken(address token, uint256 amountMinimum, address recipient) external payable; | ||
function sweepToken(Currency currency, uint256 amountMinimum, address recipient) external payable; | ||
} |