Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions app/[locale]/(user)/events/[eventSlug]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export async function generateMetadata({
const result = await GraphQLPublic(
eventBySlugQuery,
{},
{ slug: eventSlug }
{ publicId: eventSlug }
);
const event = result.eventBySlug;
const title = event?.name?.trim() || 'Event';
Expand Down Expand Up @@ -68,7 +68,7 @@ export default async function EventDetailPage({
const result = await GraphQLPublic(
eventBySlugQuery,
{},
{ slug: eventSlug }
{ publicId: eventSlug }
).catch(() => null);
const event = result?.eventBySlug;
if (!event) notFound();
Expand Down
6 changes: 3 additions & 3 deletions app/[locale]/(user)/events/queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ export type PublicEvent = {

export const eventBySlugQuery = operation<
{ eventBySlug?: PublicEvent | null },
{ slug: string }
{ publicId: string }
>(`
query EventBySlug($slug: String!) {
eventBySlug(slug: $slug) {
query EventBySlug($publicId: String!) {
eventBySlug(publicId: $publicId) {
id
name
urlSlug
Expand Down
Loading