From 8ba1d710cc87a5ecbe67ee5d7e1baaf7a4efa28c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Nie=C3=9Fen?= Date: Mon, 27 Aug 2018 13:44:19 +0200 Subject: [PATCH] crypto: make _toBuf non-enumerable Refs: https://github.com/nodejs/node/pull/22501 Refs: https://github.com/nodejs/node/pull/22519 --- lib/crypto.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/crypto.js b/lib/crypto.js index c2d3eb38cff0dd..28c5f3293d4a96 100644 --- a/lib/crypto.js +++ b/lib/crypto.js @@ -137,7 +137,6 @@ function createVerify(algorithm, options) { module.exports = exports = { // Methods - _toBuf: deprecate(toBuf, 'crypto._toBuf is deprecated.', 'DEP0114'), createCipheriv, createDecipheriv, createDiffieHellman, @@ -205,6 +204,10 @@ function getFipsForced() { } Object.defineProperties(exports, { + _toBuf: { + enumerable: false, + value: deprecate(toBuf, 'crypto._toBuf is deprecated.', 'DEP0114') + }, createCipher: { enumerable: false, value: deprecate(createCipher,