Permalink
Browse files

Close #827 Proper error message when linking invalid json thing

  • Loading branch information...
1 parent ebd0b32 commit a9fcb63368e546edb11d396dfb1fbd2de407ad9c @isaacs isaacs committed Apr 20, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/link.js
View
@@ -100,7 +100,7 @@ function linkPkg (folder, cb_) {
, readJson = require("./utils/read-json")
readJson(path.resolve(me, "package.json"), function (er, d) {
function cb (er) {
- return cb_(er, [[target, d._id]])
+ return cb_(er, [[target, d && d._id]])
}
if (er) return cb(er)
var target = path.resolve(gp, "lib", "node_modules", d.name)

0 comments on commit a9fcb63

Please sign in to comment.