cal.pub0.org/packages/trpc/server/routers/viewer/bookings/editLocation.schema.ts

12 lines
367 B
TypeScript

import { z } from "zod";
import { DailyLocationType } from "@calcom/app-store/locations";
import { commonBookingSchema } from "./types";
export const ZEditLocationInputSchema = commonBookingSchema.extend({
newLocation: z.string().transform((val) => val || DailyLocationType),
});
export type TEditLocationInputSchema = z.infer<typeof ZEditLocationInputSchema>;