fixing nullpointers....