loading 오류 수정
This commit is contained in:
@@ -5,6 +5,7 @@ import {
|
||||
toggleFavorite,
|
||||
FAVORITES_CHANGED_EVENT,
|
||||
} from '../utils/marketStorage';
|
||||
import { API_BASE } from '../utils/backendApi';
|
||||
import { UPBIT_API } from '../utils/upbitApi';
|
||||
import { fetchTickersThrottled } from '../utils/upbitTickerFetch';
|
||||
import { safeToFixed } from '../utils/safeFormat';
|
||||
@@ -98,7 +99,11 @@ export const MarketSearchPanel: React.FC<MarketSearchPanelProps> = ({
|
||||
// ── 1. 마켓 목록 로드 ─────────────────────────────────────────────────────
|
||||
useEffect(() => {
|
||||
setLoading(true);
|
||||
fetch(`${UPBIT_API}/market/all?isDetails=false`)
|
||||
fetch(`${API_BASE}/markets/all?isDetails=false`)
|
||||
.then(r => {
|
||||
if (!r.ok) return fetch(`${UPBIT_API}/market/all?isDetails=false`);
|
||||
return r;
|
||||
})
|
||||
.then(r => {
|
||||
if (!r.ok) throw new Error(`market/all ${r.status}`);
|
||||
return r.json();
|
||||
|
||||
Reference in New Issue
Block a user