Skip to content

Commit 4766454

Browse files
committed
fmt
1 parent 79b7d26 commit 4766454

File tree

1 file changed

+3
-19
lines changed

1 file changed

+3
-19
lines changed

src/EulerSwapHook.sol

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -106,23 +106,11 @@ contract EulerSwapHook is EulerSwap, BaseHook {
106106
function getHookPermissions() public pure override returns (Hooks.Permissions memory) {}
107107
function validateHookAddress(BaseHook) internal pure override {}
108108

109-
110-
111-
112-
113-
114109
error SwapLimitExceeded();
115110
error OperatorNotInstalled();
116111

117-
function computeQuote(bool asset0IsInput, uint256 amount, bool exactIn)
118-
internal
119-
view
120-
returns (uint256)
121-
{
122-
require(
123-
evc.isAccountOperatorAuthorized(eulerAccount, address(this)),
124-
OperatorNotInstalled()
125-
);
112+
function computeQuote(bool asset0IsInput, uint256 amount, bool exactIn) internal view returns (uint256) {
113+
require(evc.isAccountOperatorAuthorized(eulerAccount, address(this)), OperatorNotInstalled());
126114
require(amount <= type(uint112).max, SwapLimitExceeded());
127115

128116
// exactIn: decrease received amountIn, rounding down
@@ -146,11 +134,7 @@ contract EulerSwapHook is EulerSwap, BaseHook {
146134
return quote;
147135
}
148136

149-
function binarySearch(
150-
uint256 amount,
151-
bool exactIn,
152-
bool asset0IsInput
153-
) internal view returns (uint256 output) {
137+
function binarySearch(uint256 amount, bool exactIn, bool asset0IsInput) internal view returns (uint256 output) {
154138
int256 dx;
155139
int256 dy;
156140

0 commit comments

Comments
 (0)