Skip to content

Commit

Permalink
fix(EventJsonLd): Do not add eventStatus/eventAttendanceMode if n…
Browse files Browse the repository at this point in the history
…ot present (#1121)
  • Loading branch information
nandenjin committed Dec 3, 2022
1 parent 38838ca commit 94abb9e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/jsonld/event.tsx
Expand Up @@ -56,8 +56,10 @@ function EventJsonLd({
organizer: Array.isArray(organizer)
? organizer.map(setOrganizer)
: setOrganizer(organizer),
eventStatus: `https://schema.org/${eventStatus}`,
eventAttendanceMode: `https://schema.org/${eventAttendanceMode}`,
eventStatus: eventStatus ? `https://schema.org/${eventStatus}` : undefined,
eventAttendanceMode: eventAttendanceMode
? `https://schema.org/${eventAttendanceMode}`
: undefined,
};

return (
Expand Down

0 comments on commit 94abb9e

Please sign in to comment.