Skip to content

Commit

Permalink
Update jsonld to include virtual location when event is missing a pri…
Browse files Browse the repository at this point in the history
…mary venue
  • Loading branch information
vidya-ram committed Nov 29, 2023
1 parent 693965a commit a3c1c88
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion funnel/transports/email/send.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,10 @@ def jsonld_event_reservation(rsvp: Rsvp) -> dict[str, object]:
}
location['address'] = postal_address
else:
location = rsvp.project.location
location = {
"@type": "VirtualLocation",
"url": rsvp.project.absolute_url,
}
return {
'@context': 'https://schema.org',
'@type': 'EventReservation',
Expand All @@ -116,6 +119,7 @@ def jsonld_event_reservation(rsvp: Rsvp) -> dict[str, object]:
'performer': {
'@type': 'Organization',
'name': rsvp.project.account.title,
'image': rsvp.project.account.logo_url
},
},
'numSeats': '1',
Expand Down

0 comments on commit a3c1c88

Please sign in to comment.