fixed readfiles