quote id, fixes writing last id to file