Skip to main content

Bug Tracker

Side navigation

#5126 closed bug (fixed)

Opened August 25, 2009 10:59PM UTC

Closed June 13, 2010 05:16PM UTC

$.map should not filter undefined values?

Reported by: cwolves Owned by:
Priority: major Milestone: 1.4
Component: core Version: 1.3.2
Keywords: Cc:
Blocked by: Blocking:
Description

This is, perhaps, a design decision, but $.map filters undefined as well as null due to the fact that:

undefined == null

docs say it just filters null. There should be a double equality check:

if ( value !== null ){

Attachments (0)
Change History (1)

Changed June 13, 2010 05:16PM UTC by dmethvin comment:1

component: unfiledcore
resolution: → fixed
status: newclosed

I have updated the documentation since $.map has worked that way for several years and it might break existing code to change it.