From 8ba97c9d8b6ba258c3643fed9237bae3cf0f63d8 Mon Sep 17 00:00:00 2001 From: FragginWagon Date: Thu, 29 Jan 2026 14:27:27 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A7=20Simplify=20base=20URL=20logic=20?= =?UTF-8?q?to=20always=20use=20nginx=20proxy=20for=20CORS=20handling?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/services/challonge-v1.service.js | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/code/websites/pokedex.online/src/services/challonge-v1.service.js b/code/websites/pokedex.online/src/services/challonge-v1.service.js index ec888ea..f2bebaf 100644 --- a/code/websites/pokedex.online/src/services/challonge-v1.service.js +++ b/code/websites/pokedex.online/src/services/challonge-v1.service.js @@ -12,16 +12,10 @@ import { API_CONFIG } from '../utilities/constants.js'; /** * Get the appropriate base URL based on environment - * Development: Use Vite proxy to avoid CORS - * Production: Use direct API (requires backend proxy or CORS handling) + * Always use nginx proxy to avoid CORS issues */ function getBaseURL() { - // In development, use Vite proxy - if (import.meta.env.DEV) { - return '/api/challonge/v1/'; - } - // In production, use direct API (will need backend proxy for CORS) - return API_CONFIG.CHALLONGE_BASE_URL; + return '/api/challonge/v1/'; } /**