yt-graphql-react-event-booking-api icon indicating copy to clipboard operation
yt-graphql-react-event-booking-api copied to clipboard

Cannot read property '_doc' of null

Open azaz0 opened this issue 6 years ago • 3 comments

Hello I have some issue with taking user._doc. I used the same code. I check it line by line - letter by letter. It shows when i am trying to use query: query { events { _id title description date price creator { _id email } } } or trying to get creator id on frontend - there code is also the same. my package.json file: `{ "name": "graphql-react-ev-booking", "version": "1.0.0", "description": "", "main": "index.js", "scripts": { "test": "echo "Error: no test specified" && exit 1", "start": "nodemon app.js" }, "author": "", "license": "ISC", "dependencies": { "bcryptjs": "^2.4.3", "body-parser": "^1.18.3", "express": "^4.16.4", "express-graphql": "^0.7.1", "graphql": "^14.1.1", "jsonwebtoken": "^8.5.0", "mongoose": "^5.4.15" }, "devDependencies": { "nodemon": "^1.18.10" }

  • }`

I was tried to fix it by myself for two days i will still try. I appreciate if You look at it.

Thanks.

azaz0 avatar Feb 27 '19 21:02 azaz0

Hey azaz,

Could you please post some more information. Which file are you working in? Perhaps post a screenshot of the error you are getting?

Regards Francois

SwyserDev avatar Mar 01 '19 13:03 SwyserDev

Hey mate,

If you haven't resolved it yet, try checking your database for previous bookings where the event is null and delete them.

Hope that works!

B

Th3Botanist avatar Mar 03 '19 23:03 Th3Botanist

Hey, you made my life. It works now. I spend many hours trying solve this problem. More than enough, not enough to take that thought on start and check it. Thanks Mate :]

pon., 4 mar 2019 o 00:38 Brendan [email protected] napisał(a):

Hey mate,

If you haven't resolved it yet, try checking your database for previous bookings where the event is null and delete them.

Hope that works!

B

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/academind/yt-graphql-react-event-booking-api/issues/5#issuecomment-469077574, or mute the thread https://github.com/notifications/unsubscribe-auth/Aja_LNFHsYQaqwGYpvnfIBirTJGTH1Sbks5vTFzjgaJpZM4bVhA6 .

azaz0 avatar Mar 04 '19 08:03 azaz0