My take on this was rather that when the grep fails to produce a match, it returns an empty list to map which then operates on no extra entries - i.e. doing nothing rather than constructing an undefined value.
-M
Free your mind
Comment on Re^3: Using map and grep to Sort one list using another list