[buddypress-trac] [BuddyPress Trac] #9284: Members widget doesnt show the correct statement of "last active".
buddypress-trac
noreply at wordpress.org
Tue Jul 22 13:20:10 UTC 2025
#9284: Members widget doesnt show the correct statement of "last active".
--------------------------+-------------------------------------
Reporter: hexalibre | Owner: (none)
Type: defect (bug) | Status: new
Priority: highest | Milestone: Awaiting Contributions
Component: Core | Version: 14.3.2
Severity: major | Resolution:
Keywords: has-patch |
--------------------------+-------------------------------------
Changes (by prbot):
* keywords: needs-patch => has-patch
Comment:
''This ticket was mentioned in
[https://github.com/buddypress/buddypress/pull/413 PR #413] on
[https://github.com/buddypress/buddypress/ buddypress/buddypress] by
[https://profiles.wordpress.org/rollybueno/ @rollybueno].''
This PR fixes an issue where BuddyPress would display incorrect "time
since" values (such as "registered sometime ago") for users in non-UTC
timezones. The root cause was a mismatch between the timezone of stored
registration/activity dates (site local time) and the "current time" used
for comparison (UTC), leading to negative or inaccurate results.
**Changes**
- Updates `bp_core_time_diff()` to use the site’s timezone (via
`wp_timezone()`, available since WP 5.3) when parsing MySQL datetime
strings.
- Falls back to the previous UTC-based logic for older WordPress versions.
- Ensures both dates are compared in the same timezone, fixing the
calculation for all users regardless of site timezone.
Fixes: https://buddypress.trac.wordpress.org/ticket/9284
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/9284#comment:2>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list