hono 4.11.2 → 4.11.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -532,7 +532,8 @@ export type TypedResponse<T = unknown, U extends StatusCode = StatusCode, F exte
532
532
  _format: F;
533
533
  };
534
534
  type MergeTypedResponse<T> = T extends Promise<void> ? T : T extends Promise<infer T2> ? T2 extends TypedResponse ? T2 : TypedResponse : T extends TypedResponse ? T : TypedResponse;
535
- type MergeMiddlewareResponse<T> = T extends (c: any, next: any) => Promise<infer R> ? Exclude<R, void> extends never ? never : Exclude<R, void> extends TypedResponse ? Exclude<R, void> : never : T extends (c: any, next: any) => infer R ? R extends TypedResponse ? R : never : never;
535
+ type ExtractTypedResponseOnly<T> = T extends TypedResponse ? T : never;
536
+ type MergeMiddlewareResponse<T> = T extends (c: any, next: any) => Promise<infer R> ? Exclude<R, void> extends never ? never : Exclude<R, void> extends Response | TypedResponse<any, any, any> ? ExtractTypedResponseOnly<Exclude<R, void>> : never : T extends (c: any, next: any) => infer R ? R extends Response | TypedResponse<any, any, any> ? ExtractTypedResponseOnly<R> : never : never;
536
537
  export type FormValue = string | Blob;
537
538
  export type ParsedFormValue = string | File;
538
539
  export type ValidationTargets<T extends FormValue = ParsedFormValue, P extends string = string> = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hono",
3
- "version": "4.11.2",
3
+ "version": "4.11.3",
4
4
  "description": "Web framework built on Web Standards",
5
5
  "main": "dist/cjs/index.js",
6
6
  "type": "module",