Skip to content

Commit

Permalink
Merge pull request #153 from softeerbootcamp4th/dev
Browse files Browse the repository at this point in the history
1.0.1.1 hotfix
  • Loading branch information
lybell-art authored Oct 10, 2024
2 parents 5a4dfc9 + c825f76 commit 30205dd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/common/src/dataFetch/fetchServer.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ function createFetchOptions(options = {}) {
async function fetchServerBase(url, options = {}) {
try {
const response = await fetch(url, createFetchOptions(options));
if (response.status >= 400 && response.status <= 599) throw new HTTPError(response);
if (response.status >= 400 && response.status <= 499) throw new HTTPError(response);
if (response.status >= 500) throw new ServerCloseError();
const text = await response.text();
if (text === "") return null;
return JSON.parse(text);
Expand Down

0 comments on commit 30205dd

Please sign in to comment.