From 5f6eb5bb126e5a5cdbfe023604a4d769a8964b94 Mon Sep 17 00:00:00 2001 From: Bill Ticehurst Date: Sun, 10 Jul 2016 23:07:45 -0700 Subject: [PATCH] Removed duplicate logic (cherry picked from commit 21bf801c6cd98063ebcbd7439a49c1152717188f) --- src/compiler/program.ts | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/compiler/program.ts b/src/compiler/program.ts index 57bb3d6ae42..670d30b7d33 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -2091,13 +2091,6 @@ namespace ts { currentNodeModulesDepth++; } - if (currentNodeModulesDepth > 0) { - // If its already present with false, its a root file also. Don't override this. - if (!hasProperty(sourceFilesFoundSearchingNodeModules, resolvedPath)) { - sourceFilesFoundSearchingNodeModules[resolvedPath] = true; - } - } - const elideImport = isJsFileFromNodeModules && currentNodeModulesDepth > maxNodeModulesJsDepth; const shouldAddFile = resolution && !options.noResolve && i < file.imports.length && !elideImport;