dont need to alloc a var for writing json