MiddlewareOverride
type MiddlewareOverride = Exclude<HandlerResult, undefined | null> | voidMiddleware hooks may either keep the current handler result by returning
undefined / void, or replace it by returning any explicit handler result.
null is intentionally excluded: at runtime null is rejected by
normalizeHandlerResult the same way undefined is. A middleware that wants
to pass through the current result should return undefined / void.
Learn: Overview