From 13b6b3726aff6ba79d01fe31c79427b8dd1e384a Mon Sep 17 00:00:00 2001 From: Thomas Jeatt Date: Fri, 20 Jan 2023 10:11:32 +0000 Subject: [PATCH 1/3] wip: change fee currency --- src/adapters/interlay.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/adapters/interlay.ts b/src/adapters/interlay.ts index b3ae4128..2c91c300 100644 --- a/src/adapters/interlay.ts +++ b/src/adapters/interlay.ts @@ -32,7 +32,7 @@ export const interlayRoutersConfig: Omit[] = [ to: "statemint", token: "USDT", xcm: { - fee: { token: "DOT", amount: "1000000000" }, + fee: { token: "USDT", amount: "1000000" }, weightLimit: DEST_WEIGHT, }, }, @@ -51,7 +51,7 @@ export const kintsugiRoutersConfig: Omit[] = [ to: "statemine", token: "USDT", xcm: { - fee: { token: "KSM", amount: "1500000000" }, + fee: { token: "USDT", amount: "10000" }, weightLimit: DEST_WEIGHT, }, }, From cdaa4b76a135abdda5fbb7ed046cb76a03f4d9cb Mon Sep 17 00:00:00 2001 From: Thomas Jeatt Date: Fri, 20 Jan 2023 10:59:01 +0000 Subject: [PATCH 2/3] refactor: remove redundant conditional --- src/adapters/interlay.ts | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/src/adapters/interlay.ts b/src/adapters/interlay.ts index 2c91c300..ad3dc1b3 100644 --- a/src/adapters/interlay.ts +++ b/src/adapters/interlay.ts @@ -241,25 +241,6 @@ class BaseInterlayAdapter extends BaseCrossChainAdapter { }; } - if ( - isChainEqual(toChain, "statemine") || - isChainEqual(toChain, "statemint") - ) { - const destFee = this.getCrossChainFee(token, to); - const destWeight = this.getDestWeight(token, to); - - // do the needful, use multi currencies - return this.api.tx.xTokens.transferMulticurrencies( - [ - [tokenId, amount.toChainData()], - [{ Token: destFee.token }, destFee.balance.toChainData()], - ], - 1, - { V1: dst }, - destWeight?.toString() - ); - } - return this.api.tx.xTokens.transfer( tokenId, amount.toChainData(), From d64aebb11d5d866725bacbd725ad70f73b7e0ab2 Mon Sep 17 00:00:00 2001 From: Thomas Jeatt Date: Fri, 20 Jan 2023 14:04:59 +0000 Subject: [PATCH 3/3] chore: version bump --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 8c1757e8..aa23fde9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@interlay/bridge", - "version": "0.1.13", + "version": "0.1.14", "description": "polkawallet bridge sdk", "main": "build/index.js", "typings": "build/index.d.ts",