Back

cannot read property of null reading database

  • 0
  • Databases
  • Web
siddharthhh
29 May, 2023, 08:46

Hi, today I faced a typical issue with my app. I am using context api to store the logged in user data. I have wrapped context provider around <App/> in index.js

i have attached my user context image.

I am using this api file for backend communication- https://github.com/appwrite/demo-todo-with-react/blob/main/src/api/api.js

i have attached the error shown in console and todo.js code

when I skip the query part every thing works as usual but when I add query to filter result I get this error.(Query at line 65 in the image)

I would be really grateful if somebody could guide me through this or hint me the bug I am creating here.

TL;DR
TL;DR: The user is experiencing an issue with their app, specifically with the context API and a database query. They have provided the context image, API file, error message in console, and relevant code. They are seeking guidance or hints to resolve the bug. Solutions were not provided.
siddharthhh
29 May, 2023, 08:57

I was doing some syntactical error. sorry if someone was already working on this. 🙂

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more