Fix double /api prefix causing invite gate bypass and broken API calls
VITE_API_URL was /api but all API paths already included /api/, resulting in /api/api/config etc. Config call failed silently and defaulted to requireInvite:false. Set VITE_API_URL to empty string so paths like /api/auth/anonymous go through nginx as-is. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -112,7 +112,7 @@ export function validateStoredToken(): void {
|
||||
}
|
||||
|
||||
export const api = {
|
||||
health: () => request<{ status: string }>('/health', { timeoutMs: 5_000 }),
|
||||
health: () => request<{ status: string }>('/api/health', { timeoutMs: 5_000 }),
|
||||
auth: {
|
||||
anonymous: () => request<{ userId: string; token: string }>('/api/auth/anonymous', { method: 'POST' }),
|
||||
login: (login: string, password: string) =>
|
||||
|
||||
Reference in New Issue
Block a user