[buddypress-trac] [BuddyPress] #4090: Activity stream doesn't like scheduled post in multisite
buddypress-trac at lists.automattic.com
buddypress-trac at lists.automattic.com
Tue Mar 20 00:23:51 UTC 2012
#4090: Activity stream doesn't like scheduled post in multisite
------------------------------+------------------------------
Reporter: Prometheus Fire | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Activity | Version:
Severity: normal | Resolution:
Keywords: |
------------------------------+------------------------------
Comment (by boonebgorges):
Gah, not this issue again. Last time I "fixed" it, a bunch of people
jumped down my throat because clearly I did not know what I was talking
about; now this issue is showing the merits of the way it was before I
"fixed" it again. Oy :)
One simple strategy is to use the current server time, instead of
`post_date` or `post_modified`, when tagging the activity item. In the
case of normal write-and-then-publish posts, the values will be the same
anyway; in the case of scheduled posts, it'll end up with the correct
published date. I'll have to think about whether this would have any
effect on other types of scenarios (backdating, for instance). Feedback
welcome.
Another option is to check the previous status of the post before deciding
on a timestamp for the activity item. The problem with this is that
there's not really a reliable way of checking this. I'll have to do more
research to see if there's a place in the post-publishing process where we
can hook in and detect that a scheduled post is being published.
FWIW, it would be worth seeing what WP itself does with scheduled posts. I
don't know off the top of my head. Do they get `post_date` of the
*scheduled* time, and a `post_modified` of the time of the last save? Is
`post_date` set only once (at the time of writing), or is it changed when
the post is published? Etc.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/4090#comment:1>
BuddyPress <http://buddypress.org/>
BuddyPress
More information about the buddypress-trac
mailing list