( schema: Schema.Schema.Any )
| 771 | const responseSchema = Schema.declare(HttpServerResponse.isServerResponse) |
| 772 | |
| 773 | const makeSuccessSchema = ( |
| 774 | schema: Schema.Schema.Any |
| 775 | ): Schema.Schema<unknown, HttpServerResponse.HttpServerResponse> => { |
| 776 | const schemas = new Set<Schema.Schema.Any>() |
| 777 | HttpApiSchema.deunionize(schemas, schema) |
| 778 | return Schema.Union(...Array.from(schemas, toResponseSuccess)) as any |
| 779 | } |
| 780 | |
| 781 | const makeErrorSchema = ( |
| 782 | api: HttpApi.HttpApi.AnyWithProps |