Opened 9 years ago
Closed 9 years ago
#6453 closed defect (bug) (worksforme)
Triansient doesn't clear in bp_core_get_active_member_count
Reported by: | timfield | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 2.2.3 |
Component: | Members | Keywords: | reporter-feedback |
Cc: |
Description
function bp_core_get_active_member_count() {
in buddypress/bp-members/bp-members-functions.php
has the line
set_transient( 'bp_active_member_count', $count);
It should be ( or some other sensible time-out ) otherwise this become inaccurate over time.
set_transient( 'bp_active_member_count', $count, 1 * DAY_IN_SECONDS );
Change History (3)
Note: See
TracTickets for help on using
tickets.
Thanks for the report, timfield. Passive timing out of transients are really for data whose up-to-dateness doesn't matter too much. For counts - where it *does* matter - we use a more aggressive cache-busting strategy. That is, when a new user joints the site, the 'bp_active_member_count' transient should be deleted altogether. If this is not happening on your site, can you please give details? Is it when a new user joins, when a user is deleted, when a user is marked as spam?