Fix accessing text files