fixed null pointer