In the following get function: If parent && parent.parentNode is true and the return value is parent.parentNode.selectedIndex -- will the function return null at the end, too?
get: function( elem ) {
var parent = elem.parentNode;
if ( parent && parent.parentNode ) {
parent.parentNode.selectedIndex;
}
return null;
}
null. You needreturn parent.parentNode.selectedIndex;inside the function. And then it will returnnullonly if your condition fails.