Skip to content

Commit

Permalink
fix: fetchWithRetry에서 누락된 await 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
yeolyi committed Mar 11, 2024
1 parent 194babb commit a197907
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apis/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,13 @@ const fetchWithRetry = async (
if (method !== 'GET') return _fetch(url, method, init);

try {
return _fetch(url, method, init);
return await _fetch(url, method, init);
} catch (e) {
if (e instanceof NetworkError) throw e;
console.error(`fetchWithRetry: ${e} ${url} ${method} ${init}`);

await delay(3000);
return _fetch(url, method, init);
return await _fetch(url, method, init);
}
};

Expand Down

0 comments on commit a197907

Please sign in to comment.