diff options
author | Feross Aboukhadijeh <feross@feross.org> | 2016-07-27 06:25:03 +0300 |
---|---|---|
committer | Feross Aboukhadijeh <feross@feross.org> | 2016-07-27 06:25:03 +0300 |
commit | 759db8b481c569fda9f4ebd74c2a0b037164114c (patch) | |
tree | b50f043985c9772b4a01cdc0cf4116d7463e5da5 /index.js | |
parent | f30195dd72baa526a7ff508055de759591469a4d (diff) |
Ensure client.peerId is always a string
Diffstat (limited to 'index.js')
-rw-r--r-- | index.js | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -63,7 +63,7 @@ function WebTorrent (opts) { } else if (Buffer.isBuffer(opts.peerId)) { self.peerId = opts.peerId.toString('hex') } else { - self.peerId = Buffer.from(VERSION_PREFIX + hat(48)) + self.peerId = Buffer.from(VERSION_PREFIX + hat(48)).toString('hex') } self.peerIdBuffer = Buffer.from(self.peerId, 'hex') |