mirror of
https://github.com/haveno-dex/haveno.git
synced 2024-11-17 08:17:57 +00:00
fetch deposit txs unless cached and confirmed
This commit is contained in:
parent
23393bb4b8
commit
882f1c070a
1 changed files with 2 additions and 2 deletions
|
@ -866,7 +866,7 @@ public abstract class Trade implements Tradable, Model {
|
||||||
public MoneroTx getTakerDepositTx() {
|
public MoneroTx getTakerDepositTx() {
|
||||||
String depositTxHash = getProcessModel().getTaker().getDepositTxHash();
|
String depositTxHash = getProcessModel().getTaker().getDepositTxHash();
|
||||||
try {
|
try {
|
||||||
if (getTaker().getDepositTx() == null) getTaker().setDepositTx(depositTxHash == null ? null : getXmrWalletService().getTxWithCache(depositTxHash));
|
if (getTaker().getDepositTx() == null || !getTaker().getDepositTx().isConfirmed()) getTaker().setDepositTx(depositTxHash == null ? null : getXmrWalletService().getTxWithCache(depositTxHash));
|
||||||
return getTaker().getDepositTx();
|
return getTaker().getDepositTx();
|
||||||
} catch (MoneroError e) {
|
} catch (MoneroError e) {
|
||||||
log.error("Wallet is missing taker deposit tx " + depositTxHash);
|
log.error("Wallet is missing taker deposit tx " + depositTxHash);
|
||||||
|
@ -878,7 +878,7 @@ public abstract class Trade implements Tradable, Model {
|
||||||
public MoneroTx getMakerDepositTx() {
|
public MoneroTx getMakerDepositTx() {
|
||||||
String depositTxHash = getProcessModel().getMaker().getDepositTxHash();
|
String depositTxHash = getProcessModel().getMaker().getDepositTxHash();
|
||||||
try {
|
try {
|
||||||
if (getMaker().getDepositTx() == null) getMaker().setDepositTx(depositTxHash == null ? null : getXmrWalletService().getTxWithCache(depositTxHash));
|
if (getMaker().getDepositTx() == null || !getMaker().getDepositTx().isConfirmed()) getMaker().setDepositTx(depositTxHash == null ? null : getXmrWalletService().getTxWithCache(depositTxHash));
|
||||||
return getMaker().getDepositTx();
|
return getMaker().getDepositTx();
|
||||||
} catch (MoneroError e) {
|
} catch (MoneroError e) {
|
||||||
log.error("Wallet is missing maker deposit tx " + depositTxHash);
|
log.error("Wallet is missing maker deposit tx " + depositTxHash);
|
||||||
|
|
Loading…
Reference in a new issue