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:
authorisaacs <i@izs.me>2010-08-24 10:02:27 +0400
committerisaacs <i@izs.me>2010-08-24 10:02:27 +0400
commit740af324290e4752d85eec94289239c359c5727a (patch)
treef0217d81ddc6fdade353c0856ce908d16a2a838b
parent7be1fe7571dd45fe28f315edd4b8e438a6b0ad86 (diff)
Handle the case when there is no active version
-rw-r--r--lib/utils/read-installed.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/utils/read-installed.js b/lib/utils/read-installed.js
index a1e0a450c..503e1a856 100644
--- a/lib/utils/read-installed.js
+++ b/lib/utils/read-installed.js
@@ -42,7 +42,7 @@ function readInstalled (args, cb) {
}
var active = path.join(packageDir, "active")
fs.lstat(active, function (er, s) {
- if (!s.isSymbolicLink()) {
+ if (er || !s.isSymbolicLink()) {
data[package][version] = data[package][version] || {}
return process.nextTick(V)
}