use a fully-qualified initializer when constructing BatchLoader

This commit is contained in:
humbletim 2017-02-16 21:10:50 -05:00
parent 32e450e6c2
commit e91de1775e

View file

@ -1532,7 +1532,7 @@ QScriptValue ScriptEngine::fetchModuleSource(const QString& modulePath, const bo
qCDebug(scriptengine_module) << "require.requestScript -- clearing cache for" << modulePath;
scriptCache->deleteScript(modulePath);
}
BatchLoader* loader = new BatchLoader({ modulePath });
BatchLoader* loader = new BatchLoader(QList<QUrl>({ modulePath }));
connect(loader, &BatchLoader::finished, this, onload);
connect(this, &QObject::destroyed, loader, &QObject::deleteLater);
// fail faster? (since require() blocks the engine thread while resolving dependencies)