Removed a nullpointer validate code.