mirror of
https://github.com/sparrowwallet/sparrow.git
synced 2026-08-10 08:37:05 +00:00
compute latest block on open
This commit is contained in:
+1
-1
@@ -15,10 +15,10 @@ public class SparrowChainSupplier implements ChainSupplier {
|
||||
|
||||
public SparrowChainSupplier(Integer storedBlockHeight) {
|
||||
this.storedBlockHeight = AppServices.getCurrentBlockHeight() == null ? (storedBlockHeight != null ? storedBlockHeight : 0) : AppServices.getCurrentBlockHeight();
|
||||
this.latestBlock = computeLatestBlock();
|
||||
}
|
||||
|
||||
public void open() {
|
||||
this.latestBlock = computeLatestBlock();
|
||||
EventManager.get().register(this);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user