completionId: cgen-23094e4a72da4e0c8e2b70331f6a0196
cgen-23094e4a72da4e0c8e2b70331f6a0196
This commit is contained in:
parent
c18390cbfa
commit
60d83c97d8
1 changed files with 1 additions and 4 deletions
|
|
@ -741,9 +741,6 @@ export const AuthProvider: React.FC<{ children: React.ReactNode }> = ({
|
||||||
// Special handling for Discord - use custom OAuth endpoint
|
// Special handling for Discord - use custom OAuth endpoint
|
||||||
if (provider === "discord") {
|
if (provider === "discord") {
|
||||||
try {
|
try {
|
||||||
const apiBase =
|
|
||||||
(import.meta as any)?.env?.VITE_API_BASE || window.location.origin;
|
|
||||||
|
|
||||||
// Get current auth session to get auth token
|
// Get current auth session to get auth token
|
||||||
const { data: sessionData, error: sessionError } =
|
const { data: sessionData, error: sessionError } =
|
||||||
await supabase.auth.getSession();
|
await supabase.auth.getSession();
|
||||||
|
|
@ -765,7 +762,7 @@ export const AuthProvider: React.FC<{ children: React.ReactNode }> = ({
|
||||||
|
|
||||||
// Create temporary linking session
|
// Create temporary linking session
|
||||||
const sessionRes = await fetch(
|
const sessionRes = await fetch(
|
||||||
`${apiBase}/api/discord/create-linking-session`,
|
`${API_BASE}/api/discord/create-linking-session`,
|
||||||
{
|
{
|
||||||
method: "POST",
|
method: "POST",
|
||||||
headers: {
|
headers: {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue