Skip to content

Commit f06cddd

Browse files
author
Lena Hierzi
committed
refactore: call autoRedeem instead of autoRedeem2
1 parent f98e5ef commit f06cddd

File tree

2 files changed

+14
-11
lines changed

2 files changed

+14
-11
lines changed

contracts/OffsetHelper.sol

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ contract OffsetHelper is OffsetHelperStorage {
359359
IToucanPoolToken PoolTokenImplementation = IToucanPoolToken(_fromToken);
360360

361361
// auto redeem pool token for TCO2; will transfer automatically picked TCO2 to this contract
362-
(tco2s, amounts) = PoolTokenImplementation.redeemAuto2(_amount);
362+
(tco2s, amounts) = PoolTokenImplementation.redeemAuto(_amount);
363363

364364
// update balances
365365
balances[msg.sender][_fromToken] -= _amount;

contracts/interfaces/IToucanPoolToken.sol

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,27 @@ interface IToucanPoolToken is IERC20Upgradeable {
1212

1313
function checkEligible(address erc20Addr) external view returns (bool);
1414

15-
function checkAttributeMatching(address erc20Addr)
16-
external
17-
view
18-
returns (bool);
15+
function checkAttributeMatching(
16+
address erc20Addr
17+
) external view returns (bool);
1918

2019
function calculateRedeemFees(
2120
address[] memory tco2s,
2221
uint256[] memory amounts
2322
) external view returns (uint256);
2423

25-
function redeemMany(address[] memory tco2s, uint256[] memory amounts)
26-
external;
24+
function redeemMany(
25+
address[] memory tco2s,
26+
uint256[] memory amounts
27+
) external;
2728

28-
function redeemAuto(uint256 amount) external;
29+
function redeemAuto(
30+
uint256 amount
31+
) external returns (address[] memory tco2s, uint256[] memory amounts);
2932

30-
function redeemAuto2(uint256 amount)
31-
external
32-
returns (address[] memory tco2s, uint256[] memory amounts);
33+
function redeemAuto2(
34+
uint256 amount
35+
) external returns (address[] memory tco2s, uint256[] memory amounts);
3336

3437
function getRemaining() external view returns (uint256);
3538

0 commit comments

Comments
 (0)