Some more error checking of undefined properties