Skip to content

Commit dd9f5e9

Browse files
lddubeautclindner
authored andcommitted
fix: require.resolve in Node 12.3.0 needs an array for paths option (#110)
See nodejs/node#27827
1 parent a5248fd commit dd9f5e9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/config/ConfigFile.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ const loadFromModule = (moduleName, configContext, originalFilePath) => {
6161
adjustedModuleName = path.join(configContext.options.cwd, moduleName);
6262
config = loadConfigFile(adjustedModuleName);
6363
} else {
64-
const resolvedModule = require.resolve(adjustedModuleName, {paths: path.dirname(originalFilePath)});
64+
const resolvedModule = require.resolve(adjustedModuleName, {paths: [path.dirname(originalFilePath)]});
6565

6666
config = require(resolvedModule);
6767
}

0 commit comments

Comments
 (0)