changed how files are written