Skip to content

Commit

Permalink
Fix for #261
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Jun 11, 2014
1 parent 4c2b22c commit 18434be
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions es6-shim.js
Original file line number Diff line number Diff line change
Expand Up @@ -589,8 +589,8 @@
} else {
value = list[i];
}
if (mapFn !== undefined) {
result[i] = thisArg ? mapFn.call(thisArg, value) : mapFn(value);
if (mapFn) {
result[i] = thisArg ? mapFn.call(thisArg, value, i) : mapFn(value, i);
} else {
result[i] = value;
}
Expand Down

0 comments on commit 18434be

Please sign in to comment.