diff --git a/src/types/fetch.ts b/src/types/fetch.ts index 02c83c1c57..0b7014b4c9 100644 --- a/src/types/fetch.ts +++ b/src/types/fetch.ts @@ -16,7 +16,7 @@ export type MiddlewareOf< Route extends string, Method extends RouterMethod | "default", > = Method extends keyof InternalApi[MatchedRoutes] - ? Exclude][Method], Error | void> + ? InternalApi[MatchedRoutes][Method] : never; export type TypedInternalResponse<