Merge branch 'feature/generic-swap-support' into feature/swap-info-eps-field

# Conflicts:
#	package.json
This commit is contained in:
Dmitriy Pavlov
2023-08-10 15:32:18 +03:00
2 changed files with 3 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
{
"name": "@orionprotocol/sdk",
"version": "0.19.48-dev.1-rc-1",
"version": "0.19.48-dev.2-rc-0",
"description": "Orion Protocol SDK",
"main": "./lib/index.cjs",
"module": "./lib/index.js",

View File

@@ -5,13 +5,12 @@ import { concat, defaultAbiCoder, type BytesLike } from 'ethers/lib/utils.js';
import { safeGet, SafeArray } from '../../utils/safeGetters.js';
import type Unit from '../index.js';
import { simpleFetch } from 'simple-typed-fetch';
import type { Exchange } from '../../types.js';
const EXECUTOR_SWAP_FUNCTION = "func_70LYiww"
export type Factory = "UniswapV2" | "UniswapV3" | "Curve" | "OrionV2" | "OrionV3"
const exchangeToType: Partial<Record<Exchange, Factory>> = {
const exchangeToType: Partial<Record<string, Factory>> = {
'SPOOKYSWAP': 'UniswapV2',
'PANCAKESWAP': 'UniswapV2',
'UNISWAP': 'UniswapV2',
@@ -33,7 +32,7 @@ export type SwapInfo = {
pool: string,
assetIn: string,
assetOut: string,
factory: Exchange
factory: string
}
export type CallParams = {