From 62786ed8a3b2dee108adfb6d0a5172e03182c528 Mon Sep 17 00:00:00 2001 From: Matthew Zipkin Date: Mon, 31 Aug 2020 08:13:18 -0400 Subject: [PATCH] wallet: bump lookahead to 200 account.lookahead is saved to the database as a uint8 so values larger than 255 will overflow anyway. BIP44 only recommends a gap limit of 20 anyway so this should be plenty. --- lib/wallet/account.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/wallet/account.js b/lib/wallet/account.js index 5e9f8e995..ab5a5cd0e 100644 --- a/lib/wallet/account.js +++ b/lib/wallet/account.js @@ -50,7 +50,7 @@ class Account extends bio.Struct { this.n = 1; this.receiveDepth = 0; this.changeDepth = 0; - this.lookahead = 10; + this.lookahead = 200; this.accountKey = null; this.keys = []; @@ -833,7 +833,7 @@ Account.typesByVal = [ * @const {Number} */ -Account.MAX_LOOKAHEAD = 40; +Account.MAX_LOOKAHEAD = 200; /* * Helpers