Skip to content

Commit a326192

Browse files
OttoAllmendingerllm-git
andcommitted
feat(abstract-utxo): use PSBT getHalfSignedLegacyFormat method
Use PSBT method directly instead of importing another utility function that does the same thing. Issue: BTC-2891 Co-authored-by: llm-git <llm-git@ttll.de>
1 parent 88e3135 commit a326192

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

modules/abstract-utxo/src/recovery/backupKeyRecovery.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import type { WalletUnspent } from '../unspent';
2424
import { forCoin, RecoveryProvider } from './RecoveryProvider';
2525
import { MempoolApi } from './mempoolApi';
2626
import { CoingeckoApi } from './coingeckoApi';
27-
import { createBackupKeyRecoveryPsbt, getRecoveryAmount, toPsbtToUtxolibPsbt } from './psbt';
27+
import { createBackupKeyRecoveryPsbt, getRecoveryAmount } from './psbt';
2828

2929
type ScriptType2Of3 = utxolib.bitgo.outputScripts.ScriptType2Of3;
3030
type ChainCode = utxolib.bitgo.ChainCode;
@@ -399,7 +399,7 @@ export async function backupKeyRecovery(
399399
// which hinders the integration of the latest BitGoJS SDK with PSBT signing support.
400400
txInfo.transactionHex =
401401
params.krsProvider === 'keyternal'
402-
? utxolib.bitgo.extractP2msOnlyHalfSignedTx(toPsbtToUtxolibPsbt(psbt, coin.name)).toBuffer().toString('hex')
402+
? Buffer.from(psbt.getHalfSignedLegacyFormat()).toString('hex')
403403
: encodeTransaction(psbt).toString('hex');
404404
} else {
405405
// Sign with backup key

0 commit comments

Comments
 (0)