update schema

This commit is contained in:
Kirill Litvinov
2023-08-30 10:48:14 +03:00
parent 841ad83888
commit 1fec02f0da
4 changed files with 6 additions and 6 deletions

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "@orionprotocol/sdk",
"version": "0.19.48-dev.6-rc-0",
"version": "0.19.76",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "@orionprotocol/sdk",
"version": "0.19.48-dev.6-rc-0",
"version": "0.19.76",
"hasInstallScript": true,
"license": "ISC",
"dependencies": {

View File

@@ -1,6 +1,6 @@
{
"name": "@orionprotocol/sdk",
"version": "0.19.75",
"version": "0.19.76",
"description": "Orion Protocol SDK",
"main": "./lib/index.cjs",
"module": "./lib/index.js",

View File

@@ -64,7 +64,7 @@ export default async function generateSwapCalldata({
}
const wethAddress = safeGet(unit.contracts, "WETH")
const curveRegistryAddress = safeGet(unit.contracts, "curveRegistry")
const {assetToAddress, swapExecutorContractAddress, exchangeContractAddress} = await simpleFetch(unit.blockchainService.getInfo)();
const { assetToAddress, swapExecutorContractAddress, exchangeContractAddress } = await simpleFetch(unit.blockchainService.getInfo)();
let path = SafeArray.from(path_).map((swapInfo) => {
swapInfo.assetIn = safeGet(assetToAddress, swapInfo.assetIn);
swapInfo.assetOut = safeGet(assetToAddress, swapInfo.assetOut);
@@ -235,7 +235,7 @@ async function generateOrion3Calls(
async function generateCurveStableSwapCalls(
amount: BigNumberish,
exchangeContractAddress: string,
executorAddress: string,
executorAddress: string | undefined,
path: SafeArray<SwapInfo>,
provider: ethers.providers.JsonRpcProvider,
curveRegistry: string

View File

@@ -11,7 +11,7 @@ const infoSchema = z.object({
chainId: z.number(),
chainName: z.string(),
exchangeContractAddress: z.string(),
swapExecutorContractAddress: z.string(),
swapExecutorContractAddress: z.string().optional(),
oracleContractAddress: z.string(),
matcherAddress: z.string(),
orderFeePercent: z.number(),