replaced file with file from device