Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support seeding a file from filesystem (path string) #209

Merged
merged 6 commits into from Dec 17, 2014
Merged
Prev

hack: set name on blob to fix test exception

  • Loading branch information
feross committed Dec 16, 2014
commit b8cfe8ea3cde0f0e18d9facc1c3924e783d7f2d0
@@ -51,8 +51,14 @@ test('client.seed (Buffer, Blob)', function (t) {

// Blob
if (typeof Blob !== 'undefined') {
client2.seed(new Blob([ leavesBook ]), opts, function (torrent) {
var client2 = new WebTorrent({ dht: false, tracker: false })
var blob = new Blob([ leavesBook ])

// TODO: just pass name in the opts object – this should work
// Doing it this way until we use the create-torrent code to process inputs
// in client.seed
blob.name = opts.name
client2.seed(blob, function (torrent) {
verify(t, client2, torrent)
})
} else {
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.