do not put a tempTx for particl due to miss matching txids

This commit is contained in:
julian 2024-01-16 19:18:01 -06:00
parent 33e0059ea9
commit c29e1f0307

View file

@ -444,22 +444,24 @@ class ParticlWallet extends Bip39HDWallet
return txData.copyWith( return txData.copyWith(
raw: hexString, raw: hexString,
vSize: vSize, vSize: vSize,
tempTx: TransactionV2( tempTx: null,
walletId: walletId, // builtTx.getId() requires an isParticl flag as well but the lib does not support that yet
blockHash: null, // tempTx: TransactionV2(
hash: builtTx.getId(), // walletId: walletId,
txid: builtTx.getId(), // blockHash: null,
height: null, // hash: builtTx.getId(),
timestamp: DateTime.timestamp().millisecondsSinceEpoch ~/ 1000, // txid: builtTx.getId(),
inputs: List.unmodifiable(tempInputs), // height: null,
outputs: List.unmodifiable(tempOutputs), // timestamp: DateTime.timestamp().millisecondsSinceEpoch ~/ 1000,
version: version, // inputs: List.unmodifiable(tempInputs),
type: tempOutputs.map((e) => e.walletOwns).fold(true, (p, e) => p &= e) // outputs: List.unmodifiable(tempOutputs),
? TransactionType.sentToSelf // version: version,
: TransactionType.outgoing, // type: tempOutputs.map((e) => e.walletOwns).fold(true, (p, e) => p &= e)
subType: TransactionSubType.none, // ? TransactionType.sentToSelf
otherData: null, // : TransactionType.outgoing,
), // subType: TransactionSubType.none,
// otherData: null,
// ),
); );
} }