Back

Method PATCH is not allowed by Access-Control-Allow-Methods in preflight response.

  • 0
  • Self Hosted
  • Web
Its_MS
3 May, 2024, 12:57

Afternoon,

I am trying to allow a user to update the column for the 'card', the card has a relationship to a creator which technically links the user. It was working perfectly fine until I added the relationship, now it just spits out.

Access to XMLHttpRequest at 'https://.../v1/databases/.../collections/.../documents/...' from origin 'http://localhost:5173' has been blocked by CORS policy: Method PATCH is not allowed by Access-Control-Allow-Methods in preflight response.

Any idea on how to fix this?

TL;DR
Issue: Method PATCH is not allowed by Access-Control-Allow-Methods in preflight response for updating a column with a relationship to the user. Solution: Ensure that the CORS policy allows the PATCH method. Check the server-side configuration to include PATCH in the Access-Control-Allow-Methods header.
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