Refactor: Update auth callback logic

This commit is contained in:
gpt-engineer-app[bot]
2025-10-11 23:58:18 +00:00
parent d6f9f4d9a3
commit 5e0671f79e
3 changed files with 115 additions and 1 deletions

View File

@@ -225,7 +225,11 @@ export function AuthModal({ open, onOpenChange, defaultTab = 'signin' }: AuthMod
const { error } = await supabase.auth.signInWithOAuth({
provider,
options: {
redirectTo: `${window.location.origin}/`
redirectTo: `${window.location.origin}/auth/callback`,
// Request additional scopes for avatar access
scopes: provider === 'google'
? 'email profile'
: 'identify email'
}
});
if (error) throw error;