Removed unnecessary NULL checks