Fix missing file when file is deleted