Skip to content

Instantly share code, notes, and snippets.

/index3.js
Created May 6, 2017

Embed
What would you like to do?
var WebTorrent = require('webtorrent');
var client1 = new WebTorrent();
var client2 = new WebTorrent();
var buf = new Buffer('short novel about blah');
client1.seed(buf, { name: 'blah' }, function(torrent1) {
console.log('Seeding torrent1');
client2.add(torrent1.magnetURI, function(torrent2) {
console.log('Torrent2 ready'); // Never gets here
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.