Skip to content
Permalink
Browse files

Fixed a bug with $.map() and undefined values.

  • Loading branch information
jeresig committed Jul 4, 2006
1 parent 0027439 commit 4531ab13243f5e94e1ecfbd55e992842666d08aa
Showing with 1 addition and 1 deletion.
  1. +1 −1 jquery/jquery.js
@@ -751,7 +751,7 @@ jQuery.map = function(a,f) {
var r = [];
for ( var i = 0; i < a.length; i++ ) {
var t = f(a[i],i);
if ( t !== null ) {
if ( t !== null && t != undefined ) {
if ( t.constructor != Array ) t = [t];
r = jQuery.merge( t, r );
}

0 comments on commit 4531ab1

Please sign in to comment.
You can’t perform that action at this time.