diff options
author | Kat Marchán <kzm@sykosomatic.org> | 2017-06-05 16:31:14 -0700 |
---|---|---|
committer | Jeremiah Senkpiel <fishrock123@rocketmail.com> | 2017-06-06 14:27:48 -0400 |
commit | a4444c546211cac0f5efba8b03a681546e3e184f (patch) | |
tree | a378b37fefd4fac786850c41f32eee8d07e339c7 /deps/npm/lib/utils | |
parent | df46fcb61a6f64cebffd26c8dbd4f24c8058fe25 (diff) | |
download | android-node-v8-a4444c546211cac0f5efba8b03a681546e3e184f.tar.gz android-node-v8-a4444c546211cac0f5efba8b03a681546e3e184f.tar.bz2 android-node-v8-a4444c546211cac0f5efba8b03a681546e3e184f.zip |
deps: upgrade npm to 5.0.3
PR-URL: https://github.com/nodejs/node/pull/13487
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Diffstat (limited to 'deps/npm/lib/utils')
-rw-r--r-- | deps/npm/lib/utils/error-handler.js | 2 | ||||
-rw-r--r-- | deps/npm/lib/utils/get-publish-config.js | 16 | ||||
-rw-r--r-- | deps/npm/lib/utils/module-name.js | 2 |
3 files changed, 11 insertions, 9 deletions
diff --git a/deps/npm/lib/utils/error-handler.js b/deps/npm/lib/utils/error-handler.js index 5374d1feec..b13d42e1df 100644 --- a/deps/npm/lib/utils/error-handler.js +++ b/deps/npm/lib/utils/error-handler.js @@ -120,7 +120,7 @@ function exit (code, noLog) { }) rollbacks.length = 0 } else if (code && !noLog) { - writeLogFile(reallyExit) + writeLogFile() } else { reallyExit() } diff --git a/deps/npm/lib/utils/get-publish-config.js b/deps/npm/lib/utils/get-publish-config.js index fa475434ff..ac0ef09342 100644 --- a/deps/npm/lib/utils/get-publish-config.js +++ b/deps/npm/lib/utils/get-publish-config.js @@ -1,12 +1,16 @@ -var Conf = require('../config/core.js').Conf -var RegClient = require('npm-registry-client') -var log = require('npmlog') +'use strict' + +const clientConfig = require('../config/reg-client.js') +const Conf = require('../config/core.js').Conf +const log = require('npmlog') +const npm = require('../npm.js') +const RegClient = require('npm-registry-client') module.exports = getPublishConfig function getPublishConfig (publishConfig, defaultConfig, defaultClient) { - var config = defaultConfig - var client = defaultClient + let config = defaultConfig + let client = defaultClient log.verbose('getPublishConfig', publishConfig) if (publishConfig) { config = new Conf(defaultConfig) @@ -18,7 +22,7 @@ function getPublishConfig (publishConfig, defaultConfig, defaultClient) { s[k] = publishConfig[k] return s }, {})) - client = new RegClient(config) + client = new RegClient(clientConfig(npm, log, config)) } return { config: config, client: client } diff --git a/deps/npm/lib/utils/module-name.js b/deps/npm/lib/utils/module-name.js index 649dfac01b..43e0f5fb12 100644 --- a/deps/npm/lib/utils/module-name.js +++ b/deps/npm/lib/utils/module-name.js @@ -1,6 +1,5 @@ 'use strict' var path = require('path') -var validate = require('aproba') module.exports = moduleName module.exports.test = {} @@ -22,7 +21,6 @@ function isNotEmpty (str) { var unknown = 0 function moduleName (tree) { - validate('O', arguments) var pkg = tree.package || tree if (isNotEmpty(pkg.name)) return pkg.name var pkgName = pathToPackageName(tree.path) |