fix main file issues