Opened 6 years ago
Closed 4 years ago
#4675 closed defect (bug) (reported-upstream)
Profile activity: WordCamp year shown twice
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Component: | WordCamp Site & Plugins | Keywords: | |
Cc: |
Description
As per picture, there is no need to add the WordCamp year if it is already present in the name.
Attachments (1)
Change History (4)
This ticket was mentioned in Slack in #meta-wordcamp by coreymckrill. View the logs.
5 years ago
#3
@
4 years ago
- Resolution set to reported-upstream
- Status changed from new to closed
This ticket has been moved to GitHub https://github.com/WordPress/wordcamp.org/issues/638
Note: See
TracTickets for help on using
tickets.
I believe this falls on the WordCamp side of things and may've just been a temporary situation based on WordCamp naming that has since been corrected (though that wouldn't "fix" the activity entries that had already been created).
The activity log strings for WordCamp speakers (as cited in ticket's screenshot) is constructed within the Profiles activity handler. It directly uses the
wordcamp_name
value as sent in the data payload from WordCamp.org. Which means "WordCamp Moscow 2018 2018" was what was sent to Profiles.WordCamp sends as the
wordcamp_name
payload the return value ofget_wordcamp_name()
. That function does append a year to the WordCamp name provided in the corresponding post.The function description says:
The code does not check to see if the post title already contains a year, so the convention probably is to not include the year there. WordCamp Moscow 2018 probably put the year in there. As speakers were confirmed,
get_wordcamp_name()
tacked on the year, resulting in "WordCamp Moscow 2018 2018". The activity entries would require a manual update of database fields to remove the duplicate year since they are stored as strings.On the WordCamp side of things,
get_wordcamp_name()
should probably account for the possibility of a year in the post title and not append one if already present.