diff options
Diffstat (limited to 'deps/npm/lib/uninstall.js')
-rw-r--r-- | deps/npm/lib/uninstall.js | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/deps/npm/lib/uninstall.js b/deps/npm/lib/uninstall.js index 68869f5790..600c681974 100644 --- a/deps/npm/lib/uninstall.js +++ b/deps/npm/lib/uninstall.js @@ -28,12 +28,11 @@ function uninstall (args, cb) { if (args.length) return uninstall_(args, nm, cb) // remove this package from the global space, if it's installed there - if (npm.config.get("global")) return cb(uninstall.usage) - readJson(path.resolve(npm.prefix, "package.json"), function (er, pkg) { + readJson(path.resolve(npm.localPrefix, "package.json"), function (er, pkg) { if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er) if (er) return cb(uninstall.usage) uninstall_( [pkg.name] - , npm.dir + , npm.globalDir , cb ) }) |