Comparing version 1.1.6 to 2.0.0
@@ -11,3 +11,3 @@ const ip = exports; | ||
if (this.isV4Format(ip)) { | ||
result = buff || new Buffer(offset + 4); | ||
result = buff || Buffer.alloc(offset + 4); | ||
ip.split(/\./g).map((byte) => { | ||
@@ -47,3 +47,3 @@ result[offset++] = parseInt(byte, 10) & 0xff; | ||
result = buff || new Buffer(offset + 16); | ||
result = buff || Buffer.alloc(offset + 16); | ||
for (i = 0; i < sections.length; i++) { | ||
@@ -119,3 +119,3 @@ const word = parseInt(sections[i], 16); | ||
} | ||
const buff = new Buffer(len); | ||
const buff = Buffer.alloc(len); | ||
@@ -139,3 +139,3 @@ for (let i = 0, n = buff.length; i < n; ++i) { | ||
const result = new Buffer(Math.max(addr.length, mask.length)); | ||
const result = Buffer.alloc(Math.max(addr.length, mask.length)); | ||
@@ -142,0 +142,0 @@ // Same protocol - do bitwise and |
{ | ||
"name": "ip", | ||
"version": "1.1.6", | ||
"version": "2.0.0", | ||
"author": "Fedor Indutny <fedor@indutny.com>", | ||
@@ -5,0 +5,0 @@ "homepage": "https://github.com/indutny/node-ip", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
13607
0