From 4ab20f4774f5908fcd9ca836cc0a34289bbdd68d Mon Sep 17 00:00:00 2001 From: Dominik Buszowiecki Date: Fri, 23 Aug 2024 12:55:04 -0400 Subject: [PATCH] revert --- src/build/shared.ts | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/src/build/shared.ts b/src/build/shared.ts index f7e571975a567..959e5e127ffad 100644 --- a/src/build/shared.ts +++ b/src/build/shared.ts @@ -9,22 +9,3 @@ export const resolveRemoteApiSpec = async (): Promise => { ); return response.json() as Promise; }; - -export const resolveSpecWithXHR = new Promise((resolve, reject) => { - const xhr = new XMLHttpRequest(); - xhr.onreadystatechange = () => { - if (xhr.readyState === XMLHttpRequest.DONE) { - return resolve(JSON.parse(xhr.responseText) as DeRefedOpenAPI); - } - if (xhr.readyState === XMLHttpRequest.UNSENT) { - return reject('Failed to fetch schema'); - } - return undefined; - }; - xhr.open( - 'GET', - `https://raw.githubusercontent.com/getsentry/sentry-api-schema/${SENTRY_API_SCHEMA_SHA}/openapi-derefed.json`, - true - ); - xhr.send(null); -});