bittorrent-relay
Advanced tools
Comparing version 9.0.7 to 9.0.8
{ | ||
"name": "bittorrent-relay", | ||
"description": "Uses the mainline dht to relay requests to other trackers in a swarm", | ||
"version": "9.0.7", | ||
"version": "9.0.8", | ||
"bin": { | ||
@@ -6,0 +6,0 @@ "bittorrent-relay": "./bin/cmd.js" |
@@ -403,2 +403,12 @@ import Debug from 'debug' | ||
res.end(JSON.stringify(arr)) | ||
} else if(req.method === 'GET' && req.url === '/extra-ids.json' && this.tracks){ | ||
res.setHeader('Content-Type', 'application/json') | ||
res.end(JSON.stringify(Array.from(self.dataTrackers.keys()))) | ||
} else if(req.method === 'GET' && req.url === '/extra-keys.json' && this.tracks){ | ||
const arr = [] | ||
for(const i in self.dataRelays.values()){ | ||
arr.push(i.key) | ||
} | ||
res.setHeader('Content-Type', 'application/json') | ||
res.end(JSON.stringify(arr)) | ||
} else if(req.method === 'GET' && req.url === '/index.json'){ | ||
@@ -405,0 +415,0 @@ res.setHeader('Content-Type', 'application/json') |
94838
2477