Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Do not try other cacheName if in the middle of the resolve process.

  • Loading branch information...
commit 0440e6916b97c120d1a9eff706c1c9a65d95ab3c 1 parent 624886b
André Cruz satazor authored
Showing with 3 additions and 2 deletions.
  1. +3 −2 lib/core/package.js
5 lib/core/package.js
View
@@ -856,8 +856,9 @@ Package.prototype.generateResourceId = function () {
this.resourceId = crypto.createHash('md5').update(this.gitUrl).digest('hex');
this.gitPath = path.join(config.cache, this.cacheName, this.resourceId);
- // If the cache folder does not exists, try guessing it again from the new gitUrl
- if (!fs.existsSync(this.gitPath)) {
+ // If we are not in the middle of the resolve process and if the cache folder
+ // does not exists, try guessing it again from the new gitUrl
+ if (!this.unitWork.isLocked(this.cacheName) && !fs.existsSync(this.gitPath)) {
this.cacheName = this.guessName(this.cacheName);
this.gitPath = path.join(config.cache, this.cacheName, this.resourceId);
}
Please sign in to comment.
Something went wrong with that request. Please try again.