can write to file now with the new structure