From fa5d2688545561265c83c79d6685a565c565078b Mon Sep 17 00:00:00 2001 From: qwer951123 Date: Wed, 26 Jul 2023 11:16:53 +0800 Subject: [PATCH] fix bifrost balance query --- package.json | 2 +- src/adapters/bifrost.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 0352d2e0..4fe84077 100644 --- a/package.json +++ b/package.json @@ -55,5 +55,5 @@ "jest": "^28.1.1", "typescript": "^4.7.4" }, - "stableVersion": "0.1.5-7" + "stableVersion": "0.1.5-8" } diff --git a/src/adapters/bifrost.ts b/src/adapters/bifrost.ts index 10cde47b..ed7aa3e3 100644 --- a/src/adapters/bifrost.ts +++ b/src/adapters/bifrost.ts @@ -127,10 +127,10 @@ class BifrostBalanceAdapter extends BalanceAdapter { return storage.observable.pipe( map(({ data }) => ({ free: FN.fromInner(data.free.toString(), this.decimals), - locked: FN.fromInner(data.miscFrozen.toString(), this.decimals), + locked: FN.fromInner(data.frozen.toString(), this.decimals), reserved: FN.fromInner(data.reserved.toString(), this.decimals), available: FN.fromInner( - data.free.sub(data.miscFrozen).toString(), + data.free.sub(data.frozen).toString(), this.decimals ), }))