forEach inception

This commit is contained in:
Nicolas Stepien 2011-10-10 01:10:13 +02:00
parent c5bc77c401
commit 0d98ff469c
2 changed files with 5 additions and 8 deletions

View File

@ -3002,7 +3002,7 @@
};
Main = {
init: function() {
var callback, cutoff, hiddenThreads, id, lastChecked, nodes, now, timestamp, tzOffset, _i, _len, _ref, _ref2;
var cutoff, hiddenThreads, id, lastChecked, nodes, now, timestamp, tzOffset, _ref;
$.unbind(document, 'DOMContentLoaded', Main.init);
if (location.hostname === 'sys.4chan.org') {
QR.sys();
@ -3132,11 +3132,9 @@
}
}
nodes = $$('.op').concat($$('a + table'));
_ref2 = g.callbacks;
for (_i = 0, _len = _ref2.length; _i < _len; _i++) {
callback = _ref2[_i];
nodes.forEach(callback);
}
g.callbacks.forEach(function(callback) {
return nodes.forEach(callback);
});
$.bind($('form[name=delform]'), 'DOMNodeInserted', nodeInserted);
options.init();
if (!$.get('firstrun')) {

View File

@ -2370,8 +2370,7 @@ Main =
expandComment.init()
nodes = $$('.op').concat $$ 'a + table'
for callback in g.callbacks
nodes.forEach callback
g.callbacks.forEach (callback) -> nodes.forEach callback
$.bind $('form[name=delform]'), 'DOMNodeInserted', nodeInserted
options.init()