From 8f0c7ef6c76290578cf360f74e4336b0f4874a6c Mon Sep 17 00:00:00 2001 From: Richard Knoll Date: Tue, 6 Sep 2016 12:46:27 -0700 Subject: [PATCH] Pass the right host to getEffectiveTyperoots --- src/compiler/program.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/compiler/program.ts b/src/compiler/program.ts index fdb4952d21b..96356ea34aa 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -225,7 +225,7 @@ namespace ts { traceEnabled }; - const typeRoots = getEffectiveTypeRoots(options, host.getCurrentDirectory && host.getCurrentDirectory()); + const typeRoots = getEffectiveTypeRoots(options, host); if (traceEnabled) { if (containingFile === undefined) { if (typeRoots === undefined) { @@ -1086,7 +1086,7 @@ namespace ts { // Walk the primary type lookup locations const result: string[] = []; if (host.directoryExists && host.getDirectories) { - const typeRoots = getEffectiveTypeRoots(options, host.getCurrentDirectory && host.getCurrentDirectory()); + const typeRoots = getEffectiveTypeRoots(options, host); if (typeRoots) { for (const root of typeRoots) { if (host.directoryExists(root)) {