removed NULL pointer validation