Fix nested json structs not being nested correctly.