Fix detecting if main module is async

This commit is contained in:
zodern
2023-01-06 16:53:31 -06:00
parent 47e3eaeae1
commit 5ffe6bb780

View File

@@ -85,7 +85,9 @@ function runEagerModules(config, callback) {
var exports = config.require(path);
if (checkAsyncModule(exports)) {
mainModuleAsync = true;
if (path === config.mainModulePath) {
mainModuleAsync = true;
}
// Is an async module
exports.then(function (exports) {