Skip to content

Commit

Permalink
fix prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
jsy1218 committed Sep 24, 2024
1 parent 6ba23a1 commit 730155e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
metric,
MetricLoggerUnit,
routeToString,
SupportedRoutes
SupportedRoutes,
} from '@uniswap/smart-order-router'
import { AWSError, DynamoDB, Lambda } from 'aws-sdk'
import { ChainId, Currency, CurrencyAmount, Fraction, Token, TradeType } from '@uniswap/sdk-core'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,12 @@ export class PairTradeTypeChainId {
// This is for backward compatibility with the existing cached routes, that doesn't include V4, i.e.. doesn't support native currency routing
// If we are changing to use native currency address that doesn't have V4, we will have a temporary period of cached routes miss
// because frontend can still send in native currency as tokenIn/tokenOut, and we are not caching the wrapped addresses.
const currencyInAddress = cachedRoutes.protocolsCovered.includes(Protocol.V4) ? getAddress(cachedRoutes.currencyIn) : cachedRoutes.currencyIn.wrapped.address
const currencyOutAddress = cachedRoutes.protocolsCovered.includes(Protocol.V4) ? getAddress(cachedRoutes.currencyIn) : cachedRoutes.currencyIn.wrapped.address
const currencyInAddress = cachedRoutes.protocolsCovered.includes(Protocol.V4)
? getAddress(cachedRoutes.currencyIn)
: cachedRoutes.currencyIn.wrapped.address
const currencyOutAddress = cachedRoutes.protocolsCovered.includes(Protocol.V4)
? getAddress(cachedRoutes.currencyIn)
: cachedRoutes.currencyIn.wrapped.address

return new PairTradeTypeChainId({
currencyIn: currencyInAddress,
Expand Down

0 comments on commit 730155e

Please sign in to comment.