nullpointer check + moved file