Handle filemaps with length 0 in codemap lookups