PostgrestError
class PostgrestError extends Error {}
constructor(context: {
message: string;
details: string;
hint: string;
code: string;
});code: string;
details: string;
hint: string;
§Constructors
§
new PostgrestError(context: {
[src]message: string;
details: string;
hint: string;
code: string;
})@example
import PostgrestError from '@supabase/postgrest-js'
throw new PostgrestError({
message: 'Row level security prevented the request',
details: 'RLS denied the insert',
hint: 'Check your policies',
code: 'PGRST301',
})