Store the size of the project properly

(cherry picked from commit 16c7bcfebb)
This commit is contained in:
Ryan Cavanaugh 2017-03-21 11:37:22 -07:00 committed by Bill Ticehurst
parent 01e619ba53
commit 8b3c54dbfb

View file

@ -873,14 +873,14 @@ namespace ts.server {
continue;
}
totalNonTsFileSize += this.host.getFileSize(fileName);
if (totalNonTsFileSize > availableSpace) {
if (totalNonTsFileSize > maxProgramSizeForNonTsFiles) {
this.projectToSizeMap[name] = totalNonTsFileSize;
return true;
}
}
this.projectToSizeMap[name] = totalNonTsFileSize;
return false;
return totalNonTsFileSize < availableSpace;
}
private createAndAddExternalProject(projectFileName: string, files: protocol.ExternalFile[], options: protocol.ExternalProjectCompilerOptions, typeAcquisition: TypeAcquisition) {