From 6eb4fb2d41bfcddea543e72a6ced29df33a9a83a Mon Sep 17 00:00:00 2001 From: Tim Fish Date: Wed, 2 Oct 2024 11:39:47 +0200 Subject: [PATCH] fix: Use `force-cache` when fetching debugIds --- static/app/utils/getErrorDebugIds.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/static/app/utils/getErrorDebugIds.ts b/static/app/utils/getErrorDebugIds.ts index 5aab5267629def..9c4396363cb49b 100644 --- a/static/app/utils/getErrorDebugIds.ts +++ b/static/app/utils/getErrorDebugIds.ts @@ -33,7 +33,9 @@ export async function getErrorDebugIds(e: Error): Promise<{[filename: string]: s } try { - const text = await fetch(stackFrame.filename).then(res => res.text()); + const text = await fetch(stackFrame.filename, {cache: 'force-cache'}).then(res => + res.text() + ); const debugIdMatch = text.match(/^\/\/# debugId=(\S+)/im); if (!debugIdMatch) {