diff --git a/boot/boot.js b/boot/boot.js index 68eb80799..56742c89d 100644 --- a/boot/boot.js +++ b/boot/boot.js @@ -88,7 +88,7 @@ $tw.utils.each = function(object,callback) { Pushes a value to an array only when not yet contained. */ $tw.utils.pushOnce = function(array,value) { - if(0 > array.indexOf(value)){ + if(array.indexOf(value) == -1) { array.push(value); } } diff --git a/core/modules/filters/each.js b/core/modules/filters/each.js index a1e233a94..c60447446 100644 --- a/core/modules/filters/each.js +++ b/core/modules/filters/each.js @@ -48,4 +48,4 @@ exports.each = function(source,operator,options) { return results; }; -})(); \ No newline at end of file +})();