Let's speed that up a bit.

This commit is contained in:
Zixaphir 2013-03-16 12:26:34 -07:00
parent fc02990565
commit 4f8206f343
2 changed files with 5 additions and 6 deletions

View File

@ -7875,20 +7875,18 @@
return; return;
} }
initFeatures = function(features) { initFeatures = function(features) {
var module, name, _results; var module, name;
_results = [];
for (name in features) { for (name in features) {
module = features[name]; module = features[name];
try { try {
_results.push(module.init()); module.init();
} catch (err) { } catch (err) {
_results.push(Main.handleErrors({ Main.handleErrors({
message: "\"" + name + "\" initialization crashed.", message: "\"" + name + "\" initialization crashed.",
error: err error: err
})); });
} }
} }
return _results;
}; };
initFeatures({ initFeatures({
'Polyfill': Polyfill, 'Polyfill': Polyfill,

View File

@ -335,6 +335,7 @@ Main =
error: err error: err
# finally # finally
# c.timeEnd "#{name} initialization" # c.timeEnd "#{name} initialization"
return
# c.time 'All initializations' # c.time 'All initializations'
initFeatures initFeatures