Added partially debuging. Fixed custom file rename.