mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-12-03 18:02:54 -05:00
fix requesting block height + 1 on update trade period
This commit is contained in:
parent
49178073e4
commit
bcb46605ff
1 changed files with 1 additions and 1 deletions
|
|
@ -2635,7 +2635,7 @@ public abstract class Trade extends XmrWalletBase implements Tradable, Model {
|
|||
// get finalize time of last deposit tx
|
||||
if (getWallet() == null) throw new RuntimeException("Cannot set start time for trade " + getId() + " because cannot get its wallet");
|
||||
Long finalizeHeight = getDepositsFinalizedHeight();
|
||||
if (finalizeHeight == null || finalizeHeight > xmrConnectionService.getTargetHeight()) return; // TODO: isDepositsFinalized() can assume true, so skip if finalized height not reached
|
||||
if (finalizeHeight == null || finalizeHeight > xmrConnectionService.getTargetHeight() - 1) return; // TODO: isDepositsFinalized() can assume true, so skip if finalized height not reached
|
||||
long finalizeTime = monerod.getBlockByHeight(finalizeHeight).getTimestamp() * 1000;
|
||||
|
||||
// If block date is in future (Date in blocks can be off by +/- 2 hours) we use our current date.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue