Files
Benny JooandGitHub 03bc8db64a refactor: Remove StripeService from @calcom/lib and define it in @calcom/trpc (#23655)
* remove packages/lib/server/stripe

* simplify metadata

* define business logic directly in trpc handler
2025-09-08 02:02:56 +00:00

31 lines
798 B
TypeScript

import type { PageProps as _PageProps } from "app/_types";
import { _generateMetadata } from "app/_utils";
import { z } from "zod";
import VerifyPage from "~/auth/verify-view";
const querySchema = z.object({
stripeCustomerId: z.string().optional(),
sessionId: z.string().optional(),
t: z.string().optional(),
});
export const generateMetadata = async ({ params, searchParams }: _PageProps) => {
const p = { ...(await params), ...(await searchParams) };
const { sessionId } = querySchema.parse(p);
return await _generateMetadata(
() => (sessionId ? "Payment Page" : `Verify your email`),
() => "",
undefined,
undefined,
"/auth/verify"
);
};
const ServerPage = () => {
return <VerifyPage EMAIL_FROM={process.env.EMAIL_FROM} />;
};
export default ServerPage;