Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Shively-Sanders <293473+sandersn@users.noreply.github.com>2021-02-24 02:47:13 +0300
committerRuy Adorno <ruyadorno@hotmail.com>2021-03-04 23:57:50 +0300
commitb33c760cea7fe2696d35b5530abc1b455980fef1 (patch)
treece5310b5c6c5e253319de5fcf26d657c62c3c7d5 /tap-snapshots
parentc8b73db82f0f2445c20a0a64110586253accd66b (diff)
Remove unused arguments on various function calls
I checked cli's code with Typescript using the tsconfig below. The compiler found a few arguments that are not used, so I removed them. In the case of `npm whoami`, it is clearer that it ignores its `args` and instead relies on `npm.flatOptions`. ```json { "compilerOptions": { "moduleResolution": "node", "module": "commonjs", "resolveJsonModule": true, "target": "es2019", "noImplicitAny": false, "noImplicitThis": true, "strict": true, "maxNodeModuleJsDepth": 0, "noEmit": true, "allowJs": true, "checkJs": true, "types": ["node"], "lib": ["esnext"] }, "include": ["lib"] } ``` PR-URL: https://github.com/npm/cli/pull/2766 Credit: @sandersn Close: #2766 Reviewed-by: @nlf, @ruyadorno, @Matausi29
Diffstat (limited to 'tap-snapshots')
-rw-r--r--tap-snapshots/test-lib-utils-npm-usage.js-TAP.test.js9
1 files changed, 4 insertions, 5 deletions
diff --git a/tap-snapshots/test-lib-utils-npm-usage.js-TAP.test.js b/tap-snapshots/test-lib-utils-npm-usage.js-TAP.test.js
index ced8d1a05..aced03ecf 100644
--- a/tap-snapshots/test-lib-utils-npm-usage.js-TAP.test.js
+++ b/tap-snapshots/test-lib-utils-npm-usage.js-TAP.test.js
@@ -393,11 +393,10 @@ All commands:
prefix npm prefix [-g]
- profile npm profile disable-2fa
-
-
- common options: npm profile get [<key>]
-
+ profile npm profile enable-2fa [auth-only|auth-and-writes]
+ npm profile disable-2fa
+ npm profile get [<key>]
+ npm profile set <key> <value>
prune npm prune [[<@scope>/]<pkg>...] [--production]