From 9d8f95ee0fd8506c6f2c8e32d3a864fbaf3c108a Mon Sep 17 00:00:00 2001 From: Christopher Jeffrey Date: Sun, 18 Dec 2016 23:06:44 -0800 Subject: [PATCH] walletdb: less load for browser. --- lib/wallet/walletdb.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/wallet/walletdb.js b/lib/wallet/walletdb.js index bf50a067..35e58e02 100644 --- a/lib/wallet/walletdb.js +++ b/lib/wallet/walletdb.js @@ -601,7 +601,8 @@ WalletDB.prototype.getDepth = co(function* getDepth() { iter = this.db.iterator({ gte: layout.w(0x00000000), lte: layout.w(0xffffffff), - reverse: true + reverse: true, + limit: 1 }); item = yield iter.next();