Skip to content

Commit

Permalink
TransactionConfidence: Only apply depth if appearedAtChainHeight is n…
Browse files Browse the repository at this point in the history
…ot invalid (-1)

Cherry pick bisq-network@854ce3a
  • Loading branch information
ManfredKarrer authored and oscarguindzberg committed Dec 20, 2018
1 parent ba5e10f commit 5ed2576
Showing 1 changed file with 3 additions and 1 deletion.
Expand Up @@ -369,7 +369,9 @@ public synchronized String toString() {
* @return the new depth
*/
public synchronized int incrementDepthInBlocks(int height) {
this.depth = height - getAppearedAtChainHeight() + 1;
if (getAppearedAtChainHeight() != -1)
this.depth = height - getAppearedAtChainHeight() + 1;

return this.depth;
}

Expand Down

0 comments on commit 5ed2576

Please sign in to comment.