From c132ce47c9146738a0e7a5700aa93409b680b524 Mon Sep 17 00:00:00 2001 From: Feross Aboukhadijeh Date: Thu, 19 Mar 2015 19:48:15 -0700 Subject: internal: simplify how storage opts are passed --- index.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'index.js') diff --git a/index.js b/index.js index c3628f5..04b5989 100644 --- a/index.js +++ b/index.js @@ -154,9 +154,6 @@ WebTorrent.prototype.download = function (torrentId, opts, ontorrent) { opts.client = self opts.storage = opts.storage || self.storage - if (!opts.storageOpts) opts.storageOpts = {} - if (opts.tmp) opts.storageOpts.tmp = opts.tmp - var torrent = new Torrent(torrentId, opts) self.torrents.push(torrent) @@ -200,8 +197,7 @@ WebTorrent.prototype.seed = function (input, opts, onseed) { opts = {} } if (!opts) opts = {} - if (!opts.storageOpts) opts.storageOpts = {} - opts.storageOpts.noVerify = true + opts.noVerify = true createTorrent.parseInput(input, opts, function (err, files) { if (err) return self.emit('error', err) -- cgit v1.2.3