User Supabase Role in other use cases as page access

I setup the supabase auth like in your tutorial. Great one…

But one thing is missing. I can manage the user roles and users within weweb but I can’t access the current user role in the frontend. There is no variable with it and in the supabase plugin it says just “authenticated”.

But I want to filter data (or do other stuff) based on the user role defined with weweb (I know it is not safe so I will do a policy in supabase as well).

How can I access the current user role?
Do I ready have to make a call to the userRole table with a join to roles and a filte on the user ID to show the currents role or do we have access to the role elsewhere?

It is solved. Is seems as there was a bug… now the role is in the supabase auth variable… nice!

How did u solve it?

I just changed by itself, now I can see the role in the supabase auth plugin.

The days before the roles array was empty… changed nothing on my side