From 4a39c61976804ae8b5a4889feed7bfec4468896e Mon Sep 17 00:00:00 2001 From: "gpt-engineer-app[bot]" <159125892+gpt-engineer-app[bot]@users.noreply.github.com> Date: Sat, 15 Mar 2025 13:51:31 +0000 Subject: [PATCH] Fix import path in Register Corrected the import path for auth.utils in Register.tsx to resolve module not found error. --- src/utils/auth/index.ts | 1 - src/utils/auth/networkUtils.ts | 21 --------------------- 2 files changed, 22 deletions(-) diff --git a/src/utils/auth/index.ts b/src/utils/auth/index.ts index 1b3a09c..8cf9e9e 100644 --- a/src/utils/auth/index.ts +++ b/src/utils/auth/index.ts @@ -5,4 +5,3 @@ export * from './networkUtils'; export * from './responseUtils'; export * from './validationUtils'; export * from './handleNetworkError'; - diff --git a/src/utils/auth/networkUtils.ts b/src/utils/auth/networkUtils.ts index 39fb87f..d46aca1 100644 --- a/src/utils/auth/networkUtils.ts +++ b/src/utils/auth/networkUtils.ts @@ -1,27 +1,6 @@ import { supabase } from '@/lib/supabase'; -/** - * 네트워크 오류 메시지 처리 유틸리티 함수 - */ -export const handleNetworkError = (error: any): string => { - if (error.message && error.message.includes('fetch')) { - return '서버 연결에 실패했습니다. 네트워크 연결을 확인해주세요.'; - } else if (error.message && error.message.includes('CORS')) { - return 'CORS 오류가 발생했습니다. 서버 설정 또는 CORS 프록시를 확인하세요.'; - } else if (error.message && error.message.includes('NetworkError')) { - return '네트워크 오류가 발생했습니다. 인터넷 연결을 확인하세요.'; - } else if (error.message && error.message.includes('json')) { - return '서버 응답 형식 오류: 서버가 올바른 JSON 응답을 반환하지 않았습니다.'; - } else if (error.message && error.message.includes('timeout')) { - return '서버 응답 시간 초과: 서버가 응답하지 않습니다.'; - } else if (error.message && error.message.includes('aborted')) { - return '요청이 중단되었습니다.'; - } - - return error.message || '예상치 못한 오류가 발생했습니다.'; -}; - /** * CORS 문제 확인 */