Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
10/11/2023 11:59:27 PM (13 months ago)
Author:
imath
Message:

BP Nouveau: use the right count for the Members dynamic directory tab

In [13136] the $member_count property was wrongly used to inform about the total member count. $member_count is informing about the number of displayed members. The $total_member_count property is the right one to use.

Props Diabolique

Fixes #9001
Closes https://github.com/buddypress/buddypress/pull/173

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-templates/bp-nouveau/includes/members/functions.php

    r13503 r13593  
    527527    $members_template = $GLOBALS['members_template'];
    528528
    529     if ( isset( $members_template->member_count ) && 'all' === $args['scope'] ) {
    530         $additional_info['totalItems'] = bp_core_number_format( $members_template->member_count );
     529    if ( isset( $members_template->total_member_count ) && 'all' === $args['scope'] ) {
     530        $additional_info['totalItems'] = bp_core_number_format( $members_template->total_member_count );
    531531        $additional_info['navLabel']   = esc_html__( 'All Members', 'buddypress' );
    532532
Note: See TracChangeset for help on using the changeset viewer.