From 6e0907cc9476ec2674a166e2e3441464aa548f60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bego=C3=B1a=20=C3=81lvarez=20de=20la=20Cruz?= Date: Wed, 13 Dec 2023 14:00:33 +0100 Subject: [PATCH] fix: remove use of prepareConsolidateOutputs in vesting because it locks outputs (#7784) --- .../desktop/views/dashboard/vesting/Vesting.svelte | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/packages/desktop/views/dashboard/vesting/Vesting.svelte b/packages/desktop/views/dashboard/vesting/Vesting.svelte index c63bcdf71f8..f85b0655144 100644 --- a/packages/desktop/views/dashboard/vesting/Vesting.svelte +++ b/packages/desktop/views/dashboard/vesting/Vesting.svelte @@ -41,12 +41,10 @@ let modal: Modal let timeUntilNextPayout = DEFAULT_EMPTY_VALUE_STRING let minRequiredStorageDeposit: number | null - let hasOutputsToConsolidate = false $: ({ baseCoin } = $selectedAccountAssets[$activeProfile?.network?.id]) $: hasTransactionInProgress = $selectedAccount?.isTransferring || $selectedAccount.hasConsolidatingOutputsTransactionInProgress - $: $selectedAccount, areOutputsReadyForConsolidation() $: vestingOverview = [ { title: localize('views.vesting.overview.unlocked'), @@ -71,20 +69,12 @@ $selectedAccountVestingUnclaimedFunds > 0 && !hasTransactionInProgress && minRequiredStorageDeposit !== null && - $selectedAccount?.balances?.baseCoin?.available > minRequiredStorageDeposit && - hasOutputsToConsolidate + $selectedAccount?.balances?.baseCoin?.available > minRequiredStorageDeposit onMount(() => { getMinRequiredStorageDeposit() }) - function areOutputsReadyForConsolidation(): void { - $selectedAccount - .prepareConsolidateOutputs({ force: false, outputThreshold: 2 }) - .then(() => (hasOutputsToConsolidate = true)) - .catch(() => (hasOutputsToConsolidate = false)) - } - function getMinRequiredStorageDeposit() { getRequiredStorageDepositForMinimalBasicOutput() .then((deposit) => (minRequiredStorageDeposit = deposit))