fix invalid file