diff options
Diffstat (limited to 'test/client-seed.js')
-rw-r--r-- | test/client-seed.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/client-seed.js b/test/client-seed.js index 1f50d9b..eede4a3 100644 --- a/test/client-seed.js +++ b/test/client-seed.js @@ -1,5 +1,6 @@ /* global Blob */ +var Buffer = require('safe-buffer').Buffer var fixtures = require('webtorrent-fixtures') var test = require('tape') var WebTorrent = require('../') @@ -34,7 +35,7 @@ test('client.seed: torrent file (Buffer), set name on buffer', function (t) { client.on('error', function (err) { t.fail(err) }) client.on('warning', function (err) { t.fail(err) }) - var buf = new Buffer(fixtures.leaves.content) + var buf = Buffer.from(fixtures.leaves.content) buf.name = 'Leaves of Grass by Walt Whitman.epub' client.seed(buf, function (torrent) { |