diff options
author | isaacs <i@izs.me> | 2010-07-19 06:24:31 +0400 |
---|---|---|
committer | isaacs <i@izs.me> | 2010-07-25 05:51:19 +0400 |
commit | 641229426e05673a7ff2e7907359fc02c9559077 (patch) | |
tree | 67eacc715f4f0f477d1e902f6ac2eda2e17d8a43 /lib/uninstall.js | |
parent | 511858f0cbcfb02f1ed3cb6c67e15f826210df2f (diff) |
Don't fail uninstalling if there's no active version
Diffstat (limited to 'lib/uninstall.js')
-rw-r--r-- | lib/uninstall.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/uninstall.js b/lib/uninstall.js index f8b33be5f..e3c89d8d0 100644 --- a/lib/uninstall.js +++ b/lib/uninstall.js @@ -52,6 +52,7 @@ function uninstall (args, cb) { ( [log, "about to remove: " + pkgdir, "uninstall"] , function (cb) { fs.readlink(active, function (er, active) { + if (er) cb() if (path.basename(active||"") !== version) return cb() else if (!npm.config.get("auto-deactivate")) return cb(new Error( "cannot remove active package.\n"+ |