fix redirectToFile