Fixed nullpointer