Skip to content

Commit 52b3d23

Browse files
committed
fix(trust): update metadata generation to correctly handle async params and adjust URL format
1 parent 6237329 commit 52b3d23

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

apps/trust/src/app/[id]/page.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,10 @@ export default async function Page({ params }: { params: Promise<{ id: string }>
2626
export async function generateMetadata({
2727
params,
2828
}: {
29-
params: { id: string };
29+
params: Promise<{ id: string }>;
3030
}): Promise<Metadata> {
31-
const organization = await findOrganization(params.id);
31+
const id = (await params).id;
32+
const organization = await findOrganization(id);
3233

3334
if (!organization) {
3435
return {
@@ -38,7 +39,7 @@ export async function generateMetadata({
3839

3940
const title = `${organization.name} - Trust Center`;
4041
const description = `${organization.name} is using Comp AI to monitor their compliance against common cybersecurity frameworks like SOC 2, ISO 27001, and more.`;
41-
const url = `https://trust.trycomp.ai/${organization.id}`;
42+
const url = `https://trycomp.ai/trust/${organization.id}`;
4243

4344
return {
4445
title,

0 commit comments

Comments
 (0)