The code (in one instance) and the tests (in many instances) use Buffer(), which has been deprecated in NodeJS 6.0.0:
(node:12056) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
Maybe the approach should be to wait a couple more days until NodeJS 6 is deprecated, then update the minimum version to NodeJS 8 (EOL end of 2019) and perhaps issue a major version change.
The code (in one instance) and the tests (in many instances) use
Buffer()
, which has been deprecated in NodeJS 6.0.0:(node:12056) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
Replace
Buffer()
withBuffer.from
, which was added in NodeJS 5.10.0. All versions prior to 6, and, within days, 6 as well, are already deprecated, so this should be a benign, non-breaking change; however, package.json still shows support for 4.2.0.Maybe the approach should be to wait a couple more days until NodeJS 6 is deprecated, then update the minimum version to NodeJS 8 (EOL end of 2019) and perhaps issue a major version change.