mirror of
https://github.com/webtorrent/bittorrent-tracker.git
synced 2024-12-13 19:06:27 +00:00
client/websocket: warning on invalid info_hash
This commit is contained in:
parent
b269fb9db4
commit
df8de6f608
@ -86,7 +86,9 @@ WebSocketTracker.prototype._onSocketMessage = function (data) {
|
||||
return self.client.emit('warning', new Error('Invalid tracker response'))
|
||||
}
|
||||
|
||||
if (data.info_hash !== self.client._infoHash.toString('binary')) return
|
||||
if (data.info_hash !== self.client._infoHash.toString('binary')) {
|
||||
return self.client.emit('warning', new Error('Invalid tracker response'))
|
||||
}
|
||||
|
||||
debug('received %s from %s', JSON.stringify(data), self._announceUrl)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user