From a4f835345e495f45b40365f025afce72d1817996 Mon Sep 17 00:00:00 2001 From: Blechhirn Date: Thu, 19 May 2016 14:45:43 +0200 Subject: [PATCH] Don't call path.dirname with null/undefined Node 6+ enforces the parameter to path.dirname to be a string (https://github.com/nodejs/node/commit/08085c49b6e49ecfffd638c6cd46f4de639ae4f4). The empty string results in the previous behavior. --- index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.ts b/index.ts index 04b6881d4..b861e284c 100644 --- a/index.ts +++ b/index.ts @@ -250,13 +250,13 @@ function ensureTypeScriptInstance(loaderOptions: LoaderOptions, loader: any): { configParseResult = (compiler).parseJsonConfigFileContent( configFile.config, compiler.sys, - path.dirname(configFilePath) + path.dirname(configFilePath || '') ); } else { configParseResult = (compiler).parseConfigFile( configFile.config, compiler.sys, - path.dirname(configFilePath) + path.dirname(configFilePath || '') ); }