BP_Groups_Member::refresh_total_member_count_for_group( int $group_id )

Refresh the total_member_count for a group.

Description

Parameters

$group_id

(int) (Required) ID of the group.

Return

(bool|int) True on success, false on failure.

Source

File: bp-groups/classes/class-bp-groups-member.php

	public static function refresh_total_member_count_for_group( $group_id ) {
		return groups_update_groupmeta( $group_id, 'total_member_count', (int) BP_Groups_Group::get_total_member_count( $group_id ) );
	}

Changelog

Changelog
Version Description
BuddyPress 1.8.0 Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.