diff options
author | Ruy Adorno <ruyadorno@hotmail.com> | 2020-09-03 03:38:34 +0300 |
---|---|---|
committer | isaacs <i@izs.me> | 2020-09-04 04:27:51 +0300 |
commit | ac5aa709a8609ec2beb7a8c60b3bde18f882f4e8 (patch) | |
tree | 460a7bd21f44f935cd43012475b441793ea74362 /lib/utils | |
parent | ef8f5676b1c90dcf44256b8ed1f61ddb6277c23a (diff) |
fix: scope config
The `flatOptions.scope` option should not default to `projectScope`
since that's causing projects that have a defined `projectScope`
corresponding to configured scoped registries to try and download ALL
packages (including the ones that should be downloaded from the public
registry) to be fetch from that scoped registry url.
fix #1654
PR-URL: https://github.com/npm/cli/pull/1758
Credit: @ruyadorno
Close: #1758
Reviewed-by: @isaacs
Diffstat (limited to 'lib/utils')
-rw-r--r-- | lib/utils/flat-options.js | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/utils/flat-options.js b/lib/utils/flat-options.js index bfe6316c1..2ace852d1 100644 --- a/lib/utils/flat-options.js +++ b/lib/utils/flat-options.js @@ -68,9 +68,7 @@ const flatOptions = npm => npm.flatOptions || Object.freeze({ npm.config.get('registry'), sendMetrics: npm.config.get('send-metrics'), registry: npm.config.get('registry'), - get scope () { - return npm.projectScope - }, + scope: npm.config.get('scope'), access: npm.config.get('access'), alwaysAuth: npm.config.get('always-auth'), audit: npm.config.get('audit'), |