From 4894f6965f264456258840f2b8f053b550ba7128 Mon Sep 17 00:00:00 2001 From: Christopher Jeffrey Date: Sun, 18 May 2014 04:00:27 -0500 Subject: [PATCH] peer: txs event - only emit hashes to mimic blocks event. Signed-off-by: Fedor Indutny --- lib/bcoin/peer.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/bcoin/peer.js b/lib/bcoin/peer.js index 2472920a..179a3338 100644 --- a/lib/bcoin/peer.js +++ b/lib/bcoin/peer.js @@ -351,7 +351,9 @@ Peer.prototype._handleInv = function handleInv(items) { if (txs.length === 0) return; - this.emit('txs', txs); + this.emit('txs', txs.map(function(tx) { + return tx.hash; + })); this.getData(txs); };