diff --git a/src/compiler/sys.ts b/src/compiler/sys.ts index 6669a6fca2..0c500d5500 100644 --- a/src/compiler/sys.ts +++ b/src/compiler/sys.ts @@ -411,7 +411,7 @@ namespace ts { } function getDirectories(path: string): string[] { - return _fs.readdirSync(path); + return filter(_fs.readdirSync(path), p => fileSystemEntryExists(combinePaths(path, p), FileSystemEntryKind.Directory)); } function readDirectory(path: string, extension?: string, exclude?: string[]): string[] {