cal.pub0.org/packages/trpc/server/routers/publicViewer/session.handler.ts

12 lines
206 B
TypeScript

import type { Session } from "next-auth";
type SessionOptions = {
ctx: {
session: Session | null;
};
};
export const sessionHandler = async ({ ctx }: SessionOptions) => {
return ctx.session;
};