This commit is contained in:
Craig Raw 2022-12-07 11:00:16 +02:00
parent 12c1725260
commit df7f40dbc9

View file

@ -245,7 +245,7 @@ public class DbPersistence implements Persistence {
walletNodeDao.updateNodeAddressData(addressNode.getId(), addressNode.getAddressData()); walletNodeDao.updateNodeAddressData(addressNode.getId(), addressNode.getAddressData());
} }
Set<BlockTransactionHashIndex> txos = addressNode.getTransactionOutputs().stream().flatMap(txo -> txo.isSpent() ? Stream.of(txo, txo.getSpentBy()) : Stream.of(txo)).collect(Collectors.toSet()); List<BlockTransactionHashIndex> txos = addressNode.getTransactionOutputs().stream().flatMap(txo -> txo.isSpent() ? Stream.of(txo, txo.getSpentBy()) : Stream.of(txo)).collect(Collectors.toList());
List<Long> existingIds = txos.stream().map(Persistable::getId).filter(Objects::nonNull).collect(Collectors.toList()); List<Long> existingIds = txos.stream().map(Persistable::getId).filter(Objects::nonNull).collect(Collectors.toList());
referencedTxIds.addAll(txos.stream().map(BlockTransactionHash::getHash).collect(Collectors.toSet())); referencedTxIds.addAll(txos.stream().map(BlockTransactionHash::getHash).collect(Collectors.toSet()));