* perf: Allow bypassing 3rd party calendar busy times * Fix typing issues * Fixed API v1 build * Another fix for API v1
19 lines
481 B
TypeScript
19 lines
481 B
TypeScript
import { getUserAvailability } from "@calcom/core/getUserAvailability";
|
|
|
|
import type { TrpcSessionUser } from "../../../trpc";
|
|
import type { TUserInputSchema } from "./user.schema";
|
|
|
|
type UserOptions = {
|
|
ctx: {
|
|
user: NonNullable<TrpcSessionUser>;
|
|
};
|
|
input: TUserInputSchema;
|
|
};
|
|
|
|
export const userHandler = async ({ input }: UserOptions) => {
|
|
return getUserAvailability(
|
|
{ returnDateOverrides: true, bypassBusyCalendarTimes: false, ...input },
|
|
undefined
|
|
);
|
|
};
|