diff --git a/index.js b/index.js index 62026f38..c33c9c76 100644 --- a/index.js +++ b/index.js @@ -12,6 +12,7 @@ var parallel = require('run-parallel') var parseTorrent = require('parse-torrent') var speedometer = require('speedometer') var zeroFill = require('zero-fill') +var path = require('path') var FSStorage = require('./lib/fs-storage') // browser exclude var Storage = require('./lib/storage') @@ -208,6 +209,7 @@ WebTorrent.prototype.seed = function (input, opts, onseed) { if (!opts) opts = {} opts.noVerify = true opts.createdBy = 'WebTorrent/' + VERSION + opts.path = typeof input === 'string' ? path.dirname(input) : opts.path var streams var torrent = self.add(undefined, opts, function (torrent) {