Skip to content

Commit 3c2471c

Browse files
committed
fix: sync
1 parent 03c3987 commit 3c2471c

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

lib/net/pool.js

+3-9
Original file line numberDiff line numberDiff line change
@@ -744,7 +744,7 @@ class Pool extends EventEmitter {
744744
this.filterSyncing = true;
745745
const cFHeaderHeight = await this.chain.getCFHeaderHeight();
746746
const startHeight = cFHeaderHeight
747-
? cFHeaderHeight : 1;
747+
? cFHeaderHeight + 1 : 1;
748748
const chainHeight = await this.chain.height;
749749
const stopHeight = chainHeight > 2000 ? 2000 : chainHeight;
750750
const stopHash = await this.chain.getHash(stopHeight);
@@ -769,7 +769,7 @@ class Pool extends EventEmitter {
769769
this.filterSyncing = true;
770770
const cFilterHeight = await this.chain.getCFilterHeight();
771771
const startHeight = cFilterHeight
772-
? cFilterHeight : 1;
772+
? cFilterHeight + 1 : 1;
773773
const chainHeight = await this.chain.height;
774774
const stopHeight = chainHeight > 1000 ? 1000 : chainHeight;
775775
const stopHash = await this.chain.getHash(stopHeight);
@@ -1761,10 +1761,7 @@ class Pool extends EventEmitter {
17611761
return;
17621762

17631763
if (this.neutrino) {
1764-
const locator = await this.chain.getLocator();
1765-
this.sendLocator(locator, peer);
1766-
if (!this.syncing)
1767-
this.startFilterHeadersSync();
1764+
this.startSync();
17681765
return;
17691766
}
17701767

@@ -3668,9 +3665,6 @@ class Pool extends EventEmitter {
36683665
*/
36693666

36703667
getBlock(peer, hashes) {
3671-
if (this.options.neutrino)
3672-
return;
3673-
36743668
if (!this.opened)
36753669
return;
36763670

0 commit comments

Comments
 (0)