drop bip37 emulation.

This commit is contained in:
Christopher Jeffrey 2016-02-17 12:54:42 -08:00
parent a485a1d334
commit 2b84c16f0a

View File

@ -617,14 +617,6 @@ Pool.prototype._handleBlock = function _handleBlock(block, peer, callback) {
// Fulfill our request.
requested = self._response(block);
// Emulate BIP37: emit all the filtered transactions.
if (!self.options.spv && self.listeners('watched').length > 0) {
block.txs.forEach(function(tx) {
if (self.isWatched(tx))
self.emit('watched', tx, peer);
});
}
// Ensure the block was not invalid last time.
// Someone might be sending us bad blocks to DoS us.
if (self.block.invalid[block.hash('hex')]) {