diff --git a/frontend/src/app/components/transaction/liquid-ublinding.ts b/frontend/src/app/components/transaction/liquid-ublinding.ts index 9848949f9..cefaa4f77 100644 --- a/frontend/src/app/components/transaction/liquid-ublinding.ts +++ b/frontend/src/app/components/transaction/liquid-ublinding.ts @@ -68,7 +68,7 @@ export class LiquidUnblinding { tx._unblinded = { matched, total: this.commitments.size }; this.deduceBlinded(tx); if (matched < this.commitments.size) { - throw new Error(`Error: Invalid blinding data.`) + throw new Error(`Invalid blinding data.`) } tx._deduced = false; // invalidate cache so deduction is attempted again return tx._unblinded; diff --git a/frontend/src/app/components/transaction/transaction.component.ts b/frontend/src/app/components/transaction/transaction.component.ts index bd12b7f52..b20241834 100644 --- a/frontend/src/app/components/transaction/transaction.component.ts +++ b/frontend/src/app/components/transaction/transaction.component.ts @@ -156,10 +156,19 @@ export class TransactionComponent implements OnInit, OnDestroy { ); }) ) - .subscribe((tx: Transaction) => { + .subscribe(async (tx: Transaction) => { if (!tx) { return; } + + if (this.network === 'liquid') { + try { + await this.liquidUnblinding.checkUnblindedTx(tx) + } catch (error) { + this.errorUnblinded = error; + } + } + this.tx = tx; if (tx.fee === undefined) { this.tx.fee = 0; @@ -197,12 +206,6 @@ export class TransactionComponent implements OnInit, OnDestroy { this.fetchCpfp$.next(this.tx.txid); } } - if (this.network === 'liquid') { - this.liquidUnblinding.checkUnblindedTx(this.tx) - .catch((error) => { - this.errorUnblinded = error; - }); - } }, (error) => { this.error = error;