diff --git a/src/main/java/com/sparrowwallet/sparrow/control/EntryCell.java b/src/main/java/com/sparrowwallet/sparrow/control/EntryCell.java index ee4cfba5..ded08761 100644 --- a/src/main/java/com/sparrowwallet/sparrow/control/EntryCell.java +++ b/src/main/java/com/sparrowwallet/sparrow/control/EntryCell.java @@ -4,6 +4,7 @@ import com.sparrowwallet.drongo.KeyPurpose; import com.sparrowwallet.drongo.Utils; import com.sparrowwallet.drongo.address.Address; import com.sparrowwallet.drongo.protocol.Transaction; +import com.sparrowwallet.drongo.protocol.TransactionInput; import com.sparrowwallet.drongo.protocol.TransactionOutput; import com.sparrowwallet.drongo.wallet.*; import com.sparrowwallet.sparrow.AppServices; @@ -168,6 +169,7 @@ public class EntryCell extends TreeTableCell { .map(e -> (HashIndexEntry)e) .filter(e -> e.getType().equals(HashIndexEntry.Type.INPUT) && e.isSpendable()) .map(e -> blockTransaction.getTransaction().getInputs().get((int)e.getHashIndex().getIndex())) + .filter(TransactionInput::isReplaceByFeeEnabled) .map(txInput -> walletTxos.keySet().stream().filter(txo -> txo.getHash().equals(txInput.getOutpoint().getHash()) && txo.getIndex() == txInput.getOutpoint().getIndex()).findFirst().get()) .collect(Collectors.toList()); @@ -235,7 +237,7 @@ public class EntryCell extends TreeTableCell { } private static Double getMaxFeeRate() { - if(AppServices.getTargetBlockFeeRates().isEmpty()) { + if(AppServices.getTargetBlockFeeRates() == null || AppServices.getTargetBlockFeeRates().isEmpty()) { return 100.0; } diff --git a/src/main/java/com/sparrowwallet/sparrow/wallet/PaymentController.java b/src/main/java/com/sparrowwallet/sparrow/wallet/PaymentController.java index 45e00797..4ca6c8b2 100644 --- a/src/main/java/com/sparrowwallet/sparrow/wallet/PaymentController.java +++ b/src/main/java/com/sparrowwallet/sparrow/wallet/PaymentController.java @@ -279,7 +279,7 @@ public class PaymentController extends WalletFormController implements Initializ public void setPayment(Payment payment) { if(getRecipientValueSats() == null || payment.getAmount() != getRecipientValueSats()) { address.setText(payment.getAddress().toString()); - if(payment.getLabel() != null) { + if(payment.getLabel() != null && !label.getText().equals(payment.getLabel())) { label.setText(payment.getLabel()); } if(payment.getAmount() >= 0) {