Undo "fix" in main.js that broke the tests

This commit is contained in:
rejas 2020-04-21 12:38:29 +02:00
parent ec187fe109
commit b1fb177e4b

View File

@ -343,14 +343,16 @@ var MM = (function() {
* Loads the core config and combines it with de system defaults. * Loads the core config and combines it with de system defaults.
*/ */
var loadConfig = function() { var loadConfig = function() {
let config = window.config; // FIXME: Think about how to pass config around without breaking tests
/* eslint-disable */
if (typeof config === "undefined") { if (typeof config === "undefined") {
window.config = defaults; config = defaults;
Log.error("Config file is missing! Please create a config file."); Log.error("Config file is missing! Please create a config file.");
return; return;
} }
window.config = Object.assign({}, defaults, config); config = Object.assign({}, defaults, config);
/* eslint-enable */
}; };
/* setSelectionMethodsForModules() /* setSelectionMethodsForModules()