hez
07/05/2018, 6:07 PMconnect
in this way?
return await db.mutation.updateFoo(
{ data: {
...args,
...{ bar: {connect: { id: args.bar.id } } },
},
})
}
What does this do, if I don't pass a bar
? What if I passed a bar
on a previous update, but not on a later update?hez
07/05/2018, 6:10 PMbar
first, and then conditionally proceed to one of two mutations, or can I just have the one?