diff options
Diffstat (limited to 'lib/internal/crypto/sig.js')
-rw-r--r-- | lib/internal/crypto/sig.js | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lib/internal/crypto/sig.js b/lib/internal/crypto/sig.js index 6eda845564..27930ce1ac 100644 --- a/lib/internal/crypto/sig.js +++ b/lib/internal/crypto/sig.js @@ -1,6 +1,8 @@ 'use strict'; -const { Object } = primordials; +const { + ObjectSetPrototypeOf, +} = primordials; const { ERR_CRYPTO_SIGN_KEY_REQUIRED, @@ -38,8 +40,8 @@ function Sign(algorithm, options) { Writable.call(this, options); } -Object.setPrototypeOf(Sign.prototype, Writable.prototype); -Object.setPrototypeOf(Sign, Writable); +ObjectSetPrototypeOf(Sign.prototype, Writable.prototype); +ObjectSetPrototypeOf(Sign, Writable); Sign.prototype._write = function _write(chunk, encoding, callback) { this.update(chunk, encoding); @@ -153,8 +155,8 @@ function Verify(algorithm, options) { Writable.call(this, options); } -Object.setPrototypeOf(Verify.prototype, Writable.prototype); -Object.setPrototypeOf(Verify, Writable); +ObjectSetPrototypeOf(Verify.prototype, Writable.prototype); +ObjectSetPrototypeOf(Verify, Writable); Verify.prototype._write = Sign.prototype._write; Verify.prototype.update = Sign.prototype.update; |