Skip to content

Commit

Permalink
update sorts
Browse files Browse the repository at this point in the history
  • Loading branch information
ragokan committed Nov 6, 2023
1 parent ab9657b commit 5e5b98a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/server/src/validation/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ export type RawSchema<Output = any> = (input: unknown) => Output;

export type BunicornSchema = z.ZodSchema<any> | RawSchema | v.BaseSchema<any>;

export type __InferBunicornInput<TSchema> = TSchema extends v.BaseSchema
? v.Input<TSchema>
: TSchema extends z.ZodSchema
export type __InferBunicornInput<TSchema> = TSchema extends z.ZodSchema
? z.input<TSchema>
: TSchema extends v.BaseSchema
? v.Input<TSchema>
: TSchema extends RawSchema<infer Input>
? Input
: never;
Expand All @@ -18,10 +18,10 @@ export type __InferBunicornOutput<
Out = never
> = unknown extends TSchema
? Out
: TSchema extends v.BaseSchema
? v.Output<TSchema>
: TSchema extends z.ZodSchema
? z.output<TSchema>
: TSchema extends v.BaseSchema
? v.Output<TSchema>
: TSchema extends RawSchema
? ReturnType<TSchema>
: Out;
Expand Down

0 comments on commit 5e5b98a

Please sign in to comment.