Skip to content

Commit

Permalink
remove priceImpact filter from trades
Browse files Browse the repository at this point in the history
  • Loading branch information
Diogomartf committed Oct 2, 2024
1 parent d3cc0a1 commit 82f29a6
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/lib/eco-router/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -198,9 +198,8 @@ export async function getExactIn(
)

// remove undefined values and hight impact prices
const unsortedTrades = ecoRouterTradeList
.filter(trade => trade !== undefined || trade !== null)
.filter(trade => trade?.priceImpact.lessThan(FIVE_PERCENT)) as Trade[]
const unsortedTrades = ecoRouterTradeList.filter(trade => trade !== undefined || trade !== null) as Trade[]
// .filter(trade => trade?.priceImpact.lessThan(FIVE_PERCENT)) as Trade[]

// Return the list of sorted trades
return {
Expand Down

0 comments on commit 82f29a6

Please sign in to comment.