Register module cache as early as possible

This commit is contained in:
Kevin Sawicki 2014-10-09 14:05:23 -07:00
parent b9d89cbf5d
commit d745b9ef5f

View File

@ -3,6 +3,10 @@ window.onload = function() {
// Skip "?loadSettings=".
var loadSettings = JSON.parse(decodeURIComponent(location.search.substr(14)));
ModuleCache = require('../src/module-cache');
ModuleCache.register(loadSettings);
ModuleCache.add(loadSettings.resourcePath);
// Start the crash reporter before anything else.
require('crash-reporter').start({
productName: 'Atom',
@ -16,10 +20,6 @@ window.onload = function() {
require('coffee-script').register();
require('../src/coffee-cache').register();
ModuleCache = require('../src/module-cache');
ModuleCache.register(loadSettings);
ModuleCache.add(loadSettings.resourcePath);
require(loadSettings.bootstrapScript);
require('ipc').sendChannel('window-command', 'window:loaded')
}