Skip to content

Commit 3b35560

Browse files
committed
feat: init new Pair by custom interface
1 parent 372e6bc commit 3b35560

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/handlers/marshalling/pair-marshaller.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
import { Pair } from '@uniswap/v2-sdk'
1+
import { CustomPair } from '@axieinfinity/sdk-core'
22
import { CurrencyAmountMarshaller, MarshalledCurrencyAmount } from './currency-amount-marshaller'
33
import { Protocol } from '@uniswap/router-sdk'
4+
import { Pair } from '@uniswap/v2-sdk'
45

56
export interface MarshalledPair {
67
protocol: Protocol
@@ -18,7 +19,7 @@ export class PairMarshaller {
1819
}
1920

2021
public static unmarshal(marshalledPair: MarshalledPair): Pair {
21-
return new Pair(
22+
return new CustomPair(
2223
CurrencyAmountMarshaller.unmarshal(marshalledPair.currencyAmountA),
2324
CurrencyAmountMarshaller.unmarshal(marshalledPair.tokenAmountB)
2425
)

0 commit comments

Comments
 (0)