продолжаем вносить все
This commit is contained in:
16
index.js
Normal file
16
index.js
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
const client = new (require('./lib/client'))
|
||||||
|
const spider = new (require('./lib/spider'))(client)
|
||||||
|
|
||||||
|
//spider.on('unensureHash', (hash)=> console.log(hash))
|
||||||
|
|
||||||
|
spider.on('ensureHash', (hash, addr)=> {
|
||||||
|
console.log('new hash');
|
||||||
|
})
|
||||||
|
|
||||||
|
client.on('complete', function (metadata, infoHash) {
|
||||||
|
console.log(metadata.info);
|
||||||
|
});
|
||||||
|
|
||||||
|
// spider.on('nodes', (nodes)=>console.log('foundNodes'))
|
||||||
|
|
||||||
|
spider.listen(4445)
|
Reference in New Issue
Block a user