From f3f6cc63330a2211be982640be647daa4aadd754 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicol=C3=A1s?= Date: Fri, 7 Jun 2024 10:53:59 -0400 Subject: [PATCH] Update packages/widget/src/controllers/transfers/fungible-token-transfer.ts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Filip Štoković <59089574+sztok7@users.noreply.github.com> --- .../src/controllers/transfers/fungible-token-transfer.ts | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/packages/widget/src/controllers/transfers/fungible-token-transfer.ts b/packages/widget/src/controllers/transfers/fungible-token-transfer.ts index 51cb03e4..a2d3b863 100644 --- a/packages/widget/src/controllers/transfers/fungible-token-transfer.ts +++ b/packages/widget/src/controllers/transfers/fungible-token-transfer.ts @@ -521,11 +521,10 @@ export class FungibleTokenTransferController implements ReactiveController { return true; } case Network.SUBSTRATE: { - const substrateProvider = this.sourceSubstrateProvider; - const substrateAddress = - this.walletContext.value?.substrateWallet?.signerAddress; - if (!substrateProvider || !substrateAddress) return false; - return true; + return !!( + this.sourceSubstrateProvider && + this.walletContext.value?.substrateWallet?.signerAddress + ); } } }