RLS Error Handling
I have a policy that uses a function for the USING and its working as intended, however the response from the policy is a 404 since technically it doesnt find a matching record in the function. How do I get the RLS error to bubble up to the database query instead of just returning a 404?
When I try to make an update that'll return false for the USING I get the following -->
Im pretty sure its due to the function logic itself - which looks like this
I was assuming that RLS checks returning a boolean would fail/succeed the RLS policy and return a policy error vs a 404.
Appreciate anyone's help on this!
When I try to make an update that'll return false for the USING I get the following -->
{"body": null, "count": null, "data": null, "error": [], "status": 404, "statusText": "Not Found"}Im pretty sure its due to the function logic itself - which looks like this
I was assuming that RLS checks returning a boolean would fail/succeed the RLS policy and return a policy error vs a 404.
Appreciate anyone's help on this!