Skip to content

Commit 0c03956

Browse files
Revert "fix: check Content-Type before parsing JSON in fetchExternal (#40958)"
This reverts commit ba4b53b.
1 parent ba4b53b commit 0c03956

1 file changed

Lines changed: 0 additions & 4 deletions

File tree

src/App/src/utils/httpClient.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,6 @@ class HttpClient {
6868
if (!response.ok) {
6969
throw new Error(`${config.method || 'GET'} ${url} failed: ${response.statusText}`);
7070
}
71-
const contentType = response.headers.get('content-type') || '';
72-
if (!contentType.includes('application/json')) {
73-
throw new Error(`${config.method || 'GET'} ${url} returned non-JSON response (${contentType})`);
74-
}
7571
return response.json();
7672
}
7773
}

0 commit comments

Comments
 (0)