diff --git a/docs/organizations/org-slugs-in-urls.mdx b/docs/organizations/org-slugs-in-urls.mdx index 0ad0d8bd1e..ea98a88f7c 100644 --- a/docs/organizations/org-slugs-in-urls.mdx +++ b/docs/organizations/org-slugs-in-urls.mdx @@ -164,8 +164,8 @@ This guide is intended for apps that require org slugs in URLs. **It's recommend import { auth } from '@clerk/nextjs/server' import { OrganizationList } from '@clerk/nextjs' - export default function Home({ params }: { params: { slug: string } }) { - const { orgSlug } = auth() + export default async function Home({ params }: { params: { slug: string } }) { + const { orgSlug } = await auth(); // Check for a match between route param and active organization slug // from the user's session, and if so, show the list of valid @@ -220,8 +220,8 @@ This guide is intended for apps that require org slugs in URLs. **It's recommend import { auth } from '@clerk/nextjs/server' import { OrganizationList } from '@clerk/nextjs' - export default function Home({ params }: { params: { slug: string } }) { - const { orgSlug } = auth() + export default async function Home({ params }: { params: { slug: string } }) { + const { orgSlug } = await auth() if (params.slug != orgSlug) { return (