I’m the Mutations: Creating Links section of the R...
# orm-help
m
I’m the Mutations: Creating Links section of the React Apollo Tutorial. The CreateLink component gives an error:
Unhandled Rejection (Error): Argument id for data.postedBy.connect.id must not be null. Please use undefined instead.
I’m guessing this because you need to be logged in before you can post? Is it possible to modify the server code to allow
postedById
to be undefined or null?
e
Do you have a link to this Tutorial 🙂 ?
e
This looks like a tutorial for Apollo Client which is used by the browser to send data to the server. The error you encounter looks like it happens when the server is trying to use the request to talk to the database using prisma ( ? ) Without knowing the Graph schema and Prisma schema, it’s slightly hard to know what goes wrong. But if I have to take a wild guess, I think the data you pass in from the browser is not being converted correctly by the server into the data that prisma can use. It’s saying something about some
id
being null so I would start from there 🙂