Skip to content

Commit

Permalink
Replaced "Hosted by" with "From" on events calendar because sometimes…
Browse files Browse the repository at this point in the history
… the source is not the host. Stripped out "[O]" from to get sports name. dunno what "[O]" means
  • Loading branch information
SamuelmdLow committed Oct 8, 2024
1 parent 9a647ac commit 6fdaafd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion events/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,7 @@ async def gothunderbirds_create_event(self, ical_component):

event.description=" ".join(ical_component.get('description').split(" ")[0:-1])

splitDesc = ical_component.get('description').replace("[W] ", "").replace("[L] ", "").replace("[T] ", "").split("\n")[0].split(" ")
splitDesc = ical_component.get('description').replace("[W] ", "").replace("[L] ", "").replace("[T] ", "").replace("[O] ", "").split("\n")[0].split(" ")
splitDesc = list(filter(lambda s: s!="", splitDesc))
if len(splitDesc) > 0:
i = 0
Expand Down
2 changes: 1 addition & 1 deletion ubyssey/static_src/src/js/components/Events/calendar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ function EventInfoBox({event}) {
}></a></h2>
{event.location != "" && <p><b>Location:</b> {event.location}</p>}
<p dangerouslySetInnerHTML={
{__html: (event.host!=null ? "<b>" + (event.description ? event.host : "Hosted by " + event.host) + "</b> " : "") + event.description.replace(/(?:\r\n|\r|\n)/g, '<br>')}
{__html: (event.host!=null ? "<b>" + (event.description ? event.host : "From " + event.host) + "</b> " : "") + event.description.replace(/(?:\r\n|\r|\n)/g, '<br>')}
}>
</p>
<p>
Expand Down

0 comments on commit 6fdaafd

Please sign in to comment.