Skip to content

Commit

Permalink
MINOR Fixed multifile.js non-standard forEach() reference, using jQue…
Browse files Browse the repository at this point in the history
…ry.each() instead (from r101135)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@111640 467b73ca-7a2a-4603-9d3b-597d59a354a9
  • Loading branch information
Sam Minnee committed Oct 4, 2010
1 parent 6b9544b commit d53ea50
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions thirdparty/multifile/multifile.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,12 @@ ObservableObject.prototype = {
unsubscribe : function(evt, fn) {
this.functions = this.fns.filter(function(el) {if (el !== [evt, fn]) return el;});
},
fire : function(evt, data, scope) {
scope = scope || window
this.functions.forEach(function(el) {
if (el[0] == evt) el[1].call(scope, data);
});
}
fire : function(evt, data, scope) {
scope = scope || window
jQuery(this.functions).each(function(el) {
if (el[0] == evt) el[1].call(scope, data);
});
}
};

var MultiSelectorObserver = new ObservableObject();
Expand Down

0 comments on commit d53ea50

Please sign in to comment.