From 1c252eac8cb2c161e166851db30a83d218adcc9e Mon Sep 17 00:00:00 2001 From: Sebastian Sebbie Silbermann Date: Wed, 18 Dec 2024 23:18:33 +0100 Subject: [PATCH] [Flight] Remove unnecessary aborted check in `prerender#onError` --- packages/next/src/server/app-render/app-render.tsx | 6 ------ 1 file changed, 6 deletions(-) diff --git a/packages/next/src/server/app-render/app-render.tsx b/packages/next/src/server/app-render/app-render.tsx index 84606c6e17785..1a6510248aa14 100644 --- a/packages/next/src/server/app-render/app-render.tsx +++ b/packages/next/src/server/app-render/app-render.tsx @@ -2753,12 +2753,6 @@ async function prerenderToStream( clientReferenceManifest.clientModules, { onError: (err: unknown) => { - // TODO we can remove this once https://github.com/facebook/react/pull/31715 lands - // because we won't have onError calls when halting the prerender - if (finalServerController.signal.aborted) { - return - } - return serverComponentsErrorHandler(err) }, signal: finalServerController.signal,