lib: remove unnecessary parameter for assertCrypto()

The `exports` parameter is unnecessary.

PR-URL: https://github.com/nodejs/node/pull/10834
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sam Roberts <sam@strongloop.com>
This commit is contained in:
Jackson Tian 2017-01-16 17:19:32 +08:00
parent d86ff5fc29
commit 69674f4d3e
6 changed files with 6 additions and 6 deletions

View File

@ -1,6 +1,6 @@
'use strict';
require('internal/util').assertCrypto(exports);
require('internal/util').assertCrypto();
const assert = require('assert');
const EventEmitter = require('events');

View File

@ -1,6 +1,6 @@
'use strict';
require('internal/util').assertCrypto(exports);
require('internal/util').assertCrypto();
const assert = require('assert');
const crypto = require('crypto');

View File

@ -4,7 +4,7 @@
'use strict';
const internalUtil = require('internal/util');
internalUtil.assertCrypto(exports);
internalUtil.assertCrypto();
exports.DEFAULT_ENCODING = 'buffer';

View File

@ -1,6 +1,6 @@
'use strict';
require('internal/util').assertCrypto(exports);
require('internal/util').assertCrypto();
const tls = require('tls');
const url = require('url');

View File

@ -97,7 +97,7 @@ exports.objectToString = function objectToString(o) {
};
const noCrypto = !process.versions.openssl;
exports.assertCrypto = function(exports) {
exports.assertCrypto = function() {
if (noCrypto)
throw new Error('Node.js is not compiled with openssl crypto support');
};

View File

@ -1,7 +1,7 @@
'use strict';
const internalUtil = require('internal/util');
internalUtil.assertCrypto(exports);
internalUtil.assertCrypto();
const net = require('net');
const url = require('url');