update ref

This commit is contained in:
julian 2023-10-06 16:33:01 -06:00
parent d8e4ca03a8
commit 9c352d0e99
2 changed files with 5 additions and 5 deletions

@ -1 +1 @@
Subproject commit e97a6c25edd1ce0c441bfd181a8032275bff6c40 Subproject commit d17baa1c2ec60f544783c705496435f055830620

View file

@ -460,7 +460,7 @@ extension FusionUTXO on UTXO {
prevTxid: utf8.encode(txid), prevTxid: utf8.encode(txid),
prevIndex: vout, prevIndex: vout,
pubKey: addr.publicKey, pubKey: addr.publicKey,
amount: value, value: BigInt.from(value),
); );
} catch (e) { } catch (e) {
rethrow; rethrow;
@ -525,7 +525,7 @@ extension FusionTransaction on Transaction {
fusion.Transaction fusionTransaction = fusion.Transaction(); fusion.Transaction fusionTransaction = fusion.Transaction();
// WIP. // WIP.
fusionTransaction.Inputs = await Future.wait(inputs.map((input) async { fusionTransaction.inputs = await Future.wait(inputs.map((input) async {
// Find input amount. // Find input amount.
Map<String, dynamic> _tx = await cachedElectrumX.getTransaction( Map<String, dynamic> _tx = await cachedElectrumX.getTransaction(
coin: Coin.bitcoincash, coin: Coin.bitcoincash,
@ -565,11 +565,11 @@ extension FusionTransaction on Transaction {
prevTxid: utf8.encode(input.txid), prevTxid: utf8.encode(input.txid),
prevIndex: input.vout, prevIndex: input.vout,
pubKey: scriptPubKeyHex.toUint8ListFromHex, pubKey: scriptPubKeyHex.toUint8ListFromHex,
amount: value.raw.toInt(), value: value.raw,
); );
}).toList()); }).toList());
fusionTransaction.Outputs = await Future.wait(outputs.map((output) async { fusionTransaction.outputs = await Future.wait(outputs.map((output) async {
// TODO: maybe only need one of these but IIRC scriptPubKeyAddress is required for bitcoincash transactions? // TODO: maybe only need one of these but IIRC scriptPubKeyAddress is required for bitcoincash transactions?
if (output.scriptPubKeyAddress.isEmpty) { if (output.scriptPubKeyAddress.isEmpty) {
throw Exception("isar model output.scriptPubKeyAddress is empty!"); throw Exception("isar model output.scriptPubKeyAddress is empty!");