From 0193f58654e4236612fb35fbf368886fc9d1a05a Mon Sep 17 00:00:00 2001 From: Kirill Fomichev Date: Mon, 21 Mar 2016 14:44:14 +0300 Subject: [PATCH] buffer-equals instead buffer-equal --- lib/server/parse-udp.js | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/server/parse-udp.js b/lib/server/parse-udp.js index 78694d1..e57e53b 100644 --- a/lib/server/parse-udp.js +++ b/lib/server/parse-udp.js @@ -1,6 +1,6 @@ module.exports = parseUdpRequest -var bufferEqual = require('buffer-equal') +var bufferEquals = require('buffer-equals') var ipLib = require('ip') var common = require('../common') @@ -14,7 +14,7 @@ function parseUdpRequest (msg, rinfo) { type: 'udp' } - if (!bufferEqual(params.connectionId, common.CONNECTION_ID)) { + if (!bufferEquals(params.connectionId, common.CONNECTION_ID)) { throw new Error('received packet with invalid connection id') } diff --git a/package.json b/package.json index 5c85bb1..ab269a5 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,7 @@ "dependencies": { "bencode": "^0.7.0", "bn.js": "^4.4.0", - "buffer-equal": "^1.0.0", + "buffer-equals": "^1.0.3", "compact2string": "^1.2.0", "debug": "^2.0.0", "hat": "0.0.3",