Permalink
Browse files

refactor previous commit

  • Loading branch information...
1 parent f535c65 commit 821fcd6cf6de7297df2c9cf56aba90b314860437 @tj tj committed Feb 24, 2013
Showing with 1 addition and 3 deletions.
  1. +1 −3 lib/Package.js
View
4 lib/Package.js
@@ -58,7 +58,7 @@ function Package(pkg, version, options) {
this.auth = options.auth;
this.force = !! options.force;
this.version = version;
- this.inFlight = inFlight[this.slug];
+ if (inFlight[this.slug]) this.install = function(){};
inFlight[this.slug] = true;
}
@@ -282,8 +282,6 @@ Package.prototype.install = function(){
return this.emit('error', new Error('invalid component name "' + name + '"'));
}
- if (this.inFlight) return;
-
this.getLocalJSON(function(err, json){
if (err && err.code == 'ENOENT') {
self.reallyInstall();

0 comments on commit 821fcd6

Please sign in to comment.