moved setNestedData to the helper as well