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
path: root/lib/ls.js
diff options
context:
space:
mode:
authorRuy Adorno <ruyadorno@hotmail.com>2020-09-28 21:50:15 +0300
committernlf <quitlahok@gmail.com>2020-09-29 21:43:49 +0300
commit52114b75e83db8a5e08f23889cce41c89af9eb93 (patch)
tree92e9fbad30354da9cd65fd3b848ecd4ea408fe44 /lib/ls.js
parent2469ae5153fa4114a72684376a1b226aa07edf81 (diff)
fix: listing deps of a linked dep
npm ls was failing to properly follow symlink targets in order to find its dependencies to get printed output. PR-URL: https://github.com/npm/cli/pull/1871 Credit: @ruyadorno Close: #1871 Reviewed-by: @nlf
Diffstat (limited to 'lib/ls.js')
-rw-r--r--lib/ls.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ls.js b/lib/ls.js
index 5ea6e94ba..d55cdfb45 100644
--- a/lib/ls.js
+++ b/lib/ls.js
@@ -428,7 +428,7 @@ const ls = async (args) => {
!(node instanceof Arborist.Node) || (node[_depth] > depthToPrint)
return (shouldSkipChildren)
? []
- : [...node.edgesOut.values()]
+ : [...(node.target || node).edgesOut.values()]
.filter(filterByEdgesTypes({
dev,
development,