From 09a934f65b86b6b4f60a4c8367ad0fb1f8dfe915 Mon Sep 17 00:00:00 2001 From: sairajzero Date: Sat, 28 Jan 2023 01:41:49 +0530 Subject: [PATCH] test-fix --- lib/services/address/index.js | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/lib/services/address/index.js b/lib/services/address/index.js index 5c8e83e6..ab1907de 100644 --- a/lib/services/address/index.js +++ b/lib/services/address/index.js @@ -777,7 +777,7 @@ AddressService.prototype._streamAddressSummary = function(address, options, stre next(); }, // stream the rest of the confirmed txids out of the address index - function(next) { + async function(next) { var txIdTransformStream = new Transform({ objectMode: true }); @@ -806,11 +806,9 @@ AddressService.prototype._streamAddressSummary = function(address, options, stre var txidStream = self._getTxidStream(address, options); txidStream.pipe(txIdTransformStream); - q.drain(function (e, d){ - console.debug("Q-DRAIN", e, d); - next(e, d); - }); - + await q.drain(); + console.debug("Q-DRAIN"); + next(); } ], callback);