From 205dc05251800db90615bedef6d0b976c13f0f9f Mon Sep 17 00:00:00 2001 From: hyeonsu Date: Thu, 4 Sep 2025 16:01:33 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9A=94=EC=B2=AD=20=EC=84=9C=EB=B2=84=20?= =?UTF-8?q?=EC=A3=BC=EC=86=8C=20=EC=88=98=EC=A0=95(claude)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/lib/api/client.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/frontend/lib/api/client.ts b/frontend/lib/api/client.ts index e3d79d1a..41987d41 100644 --- a/frontend/lib/api/client.ts +++ b/frontend/lib/api/client.ts @@ -6,17 +6,18 @@ const getApiBaseUrl = (): string => { if (typeof window !== "undefined") { const currentHost = window.location.hostname; + const currentPort = window.location.port; const fullUrl = window.location.href; console.log("🌐 현재 접속 정보:", { hostname: currentHost, fullUrl: fullUrl, - port: window.location.port, + port: currentPort, }); // 로컬 개발환경: localhost:9771 → localhost:8080 - if (currentHost === "localhost" || currentHost === "127.0.0.1") { - console.log("🏠 로컬 환경 감지 → localhost:8080/api"); + if ((currentHost === "localhost" || currentHost === "127.0.0.1") && currentPort === "9771") { + console.log("🏠 로컬 개발 환경 감지 → localhost:8080/api"); return "http://localhost:8080/api"; }