Skip to content

Commit

Permalink
linted
Browse files Browse the repository at this point in the history
  • Loading branch information
mr-uniswap committed Apr 8, 2024
1 parent a709cea commit 40c1050
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions contracts/hooks/examples/LimitOrder.sol
Original file line number Diff line number Diff line change
Expand Up @@ -268,20 +268,14 @@ contract LimitOrder is BaseHook {
if (delta.amount1() != 0) revert InRange();
if (!zeroForOne) revert CrossedRange();
SafeERC20.safeTransferFrom(
IERC20(Currency.unwrap(key.currency0)),
owner,
address(poolManager),
uint256(uint128(-delta.amount0()))
IERC20(Currency.unwrap(key.currency0)), owner, address(poolManager), uint256(uint128(-delta.amount0()))
);
poolManager.settle(key.currency0);
} else {
if (delta.amount0() != 0) revert InRange();
if (zeroForOne) revert CrossedRange();
SafeERC20.safeTransferFrom(
IERC20(Currency.unwrap(key.currency0)),
owner,
address(poolManager),
uint256(uint128(-delta.amount0()))
IERC20(Currency.unwrap(key.currency0)), owner, address(poolManager), uint256(uint128(-delta.amount0()))
);
poolManager.settle(key.currency1);
}
Expand Down

0 comments on commit 40c1050

Please sign in to comment.