Skip to content

Commit a54f639

Browse files
PaulRBergfrangio
authored andcommitted
Update docs for SafeERC20.forceApprove (#4231)
(cherry picked from commit 06861dc)
1 parent e50c24f commit a54f639

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

contracts/token/ERC20/utils/SafeERC20.sol

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@ library SafeERC20 {
7676

7777
/**
7878
* @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value,
79-
* non-reverting calls are assumed to be successful. Compatible with tokens that require the approval to be set to
80-
* 0 before setting it to a non-zero value.
79+
* non-reverting calls are assumed to be successful. Meant to be used with tokens that require the approval
80+
* to be set to zero before setting it to a non-zero value, such as USDT.
8181
*/
8282
function forceApprove(IERC20 token, address spender, uint256 value) internal {
8383
bytes memory approvalCall = abi.encodeWithSelector(token.approve.selector, spender, value);

0 commit comments

Comments
 (0)