fix: rewrite auth middleware to prevent global login lock for partners and admins
All checks were successful
Staging Build / build (push) Successful in 2m46s
All checks were successful
Staging Build / build (push) Successful in 2m46s
This commit is contained in:
@@ -45,7 +45,8 @@ export async function signIn(email: string, password: string) {
|
||||
|
||||
const userId = data.user?.id
|
||||
if (userId) {
|
||||
let { data: userData, error: userError } = await supabase
|
||||
const adminClient = createAdminClient()
|
||||
let { data: userData, error: userError } = await adminClient
|
||||
.from('users')
|
||||
.select('role')
|
||||
.eq('id', userId)
|
||||
|
||||
Reference in New Issue
Block a user