You always have to be mindful whether the server expects either a GET or a POST request, because using the incorrect request type will break things.
Also, you can catch Appwrite-specific errors by attaching .catch((e) => console.log(e)) to the promise
Hey, thanks for responding Mattias
But I'm still facing the issue
As you can see this is my code snippet
But still I'm getting the error
I'm using the web sdk of appwrite
Well im out of ideas. Maybe a CORS error?
but when the user exists it doesn't give error
Take a look at my React course capstone project at https://github.com/aabmets/react-capstone-course
which uses next.js + appwrite
Take a look at the pages/account.tsx file and understand how it works
also take a look at how the appwrite context is created
my implementation works
where are you using catch()?
getSession does throw error when the user isn't logged in and that's expected
that's how you know that user is not logged in
your app looks okay what's the issue? the network request error in red that you're getting in console won't break your app since you're catching it
yaa i got it now
but will it also be shown in production?
yes it will be
and that's how it's supposed to be
okay thanks
Recommended threads
- education plan not activated
Hi I have an edu id 13103046@iubat.edu but when I am trying to claim my plan and trying to logging with github where education student plan active. the appwrite...
- 500 simultaneous OAuth logins from the s...
Hi, I'd like to ask about rate limiting around Google OAuth login on Appwrite Cloud. **OVERVIEW** Service type: A PWA (web app) for members of a university clu...
- Suspicious access pattern detected when ...
Hello, I am having trouble restoring my project. In the past it worked with no problems, but today I get an error "Suspicious access pattern detected". How can ...