Skip to content

Commit

Permalink
cb is always a function
Browse files Browse the repository at this point in the history
  • Loading branch information
medikoo committed Nov 12, 2014
1 parent dcca007 commit 7da7a0f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ext/html5/_list-construct.js
Expand Up @@ -15,7 +15,7 @@ var isFunction = require('es5-ext/function/is-function')
, memoize = require('memoizee/plain')
, getNormalizer = require('memoizee/normalizers/get-1')

, map = Array.prototype.map, call = Function.prototype.call;
, map = Array.prototype.map;

module.exports = function (childName, isChildNode) {
return function (listArg/*, renderItem, thisArg*/) {
Expand Down Expand Up @@ -59,7 +59,7 @@ module.exports = function (childName, isChildNode) {
} else if (list.forEach) {
content = [];
list.forEach(function (item, key) {
content.push(call.call(cb, this.domjs, item, key, list));
content.push(cb.call(this.domjs, item, key, list));
}, this);
}
if (!content.length && onEmpty) content = onEmpty;
Expand Down

0 comments on commit 7da7a0f

Please sign in to comment.