node: rescan before zap.

This commit is contained in:
Christopher Jeffrey 2016-10-05 19:55:55 -07:00
parent 7f22223436
commit f57867f929
No known key found for this signature in database
GPG Key ID: 8962AB9DE6666BBD
2 changed files with 6 additions and 6 deletions

View File

@ -245,12 +245,12 @@ Fullnode.prototype._open = co(function* open() {
// Ensure primary wallet.
yield this.openWallet();
// Zap stale txs.
yield this.walletdb.zap(72 * 3600);
// Rescan for any missed transactions.
yield this.rescan();
// Zap stale txs.
yield this.walletdb.zap(72 * 3600);
// Rebroadcast pending transactions.
yield this.resend();

View File

@ -168,12 +168,12 @@ SPVNode.prototype._open = co(function* open(callback) {
// Load bloom filter.
yield this.openFilter();
// Zap stale txs.
yield this.walletdb.zap(72 * 3600);
// Rescan for any missed transactions.
yield this.rescan();
// Zap stale txs.
yield this.walletdb.zap(72 * 3600);
// Rebroadcast pending transactions.
yield this.resend();