Modify ↓
Ticket #3718 (closed bug: invalid)
$.map, without any selected values, $.map won't work
| Reported by: | carl-johan.blomqvist | Owned by: | flesler |
|---|---|---|---|
| Priority: | minor | Milestone: | 1.3 |
| Component: | core | Version: | 1.2.6 |
| Keywords: | map | Cc: | carl-johan.blomqvist |
| Blocking: | Blocked by: |
Description
for example:
$("html").map(function() {
if( false ) { return $("div"); } else { return $("p"); }
}
will return all p's, but:
$("div.doesnotexist").map(function() {
if( false ) { return $("div"); } else { return $("p"); }
}
won't.
Change History
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.
Note: See
TracTickets for help on using
tickets.

That's the expected behavior. Check the docs.