We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8f21d5c commit 267d969Copy full SHA for 267d969
packages/react-router/src/server/wrapSentryHandleRequest.ts
@@ -155,8 +155,12 @@ function resolveFullRoutePath(
155
routes: Record<string, { path?: string; parentId?: string } | undefined>,
156
): string | undefined {
157
const parts: string[] = [];
158
+ // Guard against circular parentId references in corrupted route manifests
159
+ const seen = new Set<string>();
160
let currentId: string | undefined = routeId;
161
while (currentId) {
162
+ if (seen.has(currentId)) break;
163
+ seen.add(currentId);
164
const route: { path?: string; parentId?: string } | undefined = routes[currentId];
165
if (!route) break;
166
if (route.path) {
0 commit comments