File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -275,7 +275,7 @@ Server.prototype._onWebSocketRequest = function (socket, params) {
275275 } catch ( err ) {
276276 socket . send ( JSON . stringify ( {
277277 'failure reason' : err . message ,
278- info_hash : params . info_hash
278+ info_hash : common . hexToBinary ( params . info_hash )
279279 } ) , socket . onSend )
280280
281281 // even though it's an error for the client, it's just a warning for the server.
@@ -302,7 +302,7 @@ Server.prototype._onWebSocketRequest = function (socket, params) {
302302 var peers = response . peers
303303 delete response . peers
304304 response . interval = self . _intervalMs
305- response . info_hash = params . info_hash // as hex
305+ response . info_hash = common . hexToBinary ( params . info_hash )
306306
307307 socket . send ( JSON . stringify ( response ) , socket . onSend )
308308 debug ( 'sent response %s to %s' , JSON . stringify ( response ) , params . peer_id )
You can’t perform that action at this time.
0 commit comments