Skip to:
Content
Pages
Categories
Search
Top
Bottom

Why Does Group Count Not Go Down When You Delete Group

  • @webgyrl

    Member

    Hi,

    I have been running a series of tests as I install things on BP and have noticed that when I have created a test group and then deleted it, the count remains the same. Is there a way to fix this.

    For example, I have 7 actual groups, but it is showing 14 in the count:
    http://i31.tinypic.com/2j4wuf9.jpg

    None of my groups are private or hidden.

    Thanks for any assistance you can give

Viewing 15 replies - 1 through 15 (of 15 total)
  • @thisisjamessmith

    Participant

    I have the same problem – did you find any resolution?

    I’m also finding that deleting a group does not delete its forum from the wp_bb_forums database table

    @djpaul

    Keymaster

    Works for me ok on BP 1.2.6 (i.e. BP 1.2 branch). What versions of BP and WP are you using please?

    @thisisjamessmith

    Participant

    running on WP 3.0.0 and BP 1.2.5.2. Only unusual thing is that I’m using a proxy for external http connections. Any idea how I can troubleshoot? (The debug mode is not much help because of this other problem: https://buddypress.org/community/groups/installing-buddypress/forum/topic/installed-and-activated-buddypress-wall-of-warnings/)

    @djpaul

    Keymaster

    Are you sure the group records are being deleted from the database?

    @nuprn1

    Participant

    running any cache plugins?

    groups_get_total_group_count() is wp_cache and is removed on the action groups_group_deleted

    as for deleting a group and the associated bbPress table – correct, currently BuddyPress does not remove it from the bb_forums table (or even removing other data – topics, etc – https://trac.buddypress.org/ticket/2613 )

    @thisisjamessmith

    Participant

    not running any caching yet, no.

    I’ve narrowed down the problem however – it actually seems to be caused by deleting the wp USER who created the group. Doing that removes the user’s group(s) from the listings page, but doesn’t remove them from wp_bp_groups (and therefore the count is also incorrect).

    thanks for clarifying on the bb forum thing.

    @djpaul

    Keymaster

    I’ve just put a patch on that ticket for the “bb forum thing” so hopefully that will make BP 1.2.6. You’ll have to manually clean up any orphan forums.

    @djpaul

    Keymaster

    We have a winner!

    @djpaul

    Keymaster

    @thisisjamessmith

    Participant

    Thanks all for the speedy patches. As JJJ points out, the first one will be tricky to get ‘right’… needs the option to reassign groups to a given user instead of deleting.

    @nuprn1

    Participant

    maybe interim solution – autoassign a group admin at group creation (sample code, just need to have a account setup and replace the user_id. ie, in my case i use a dummy groupadmin user for all groups)
    http://etivite.com/groups/buddypress/forum/topic/quick-tip-auto-assign-member-as-group-mod-or-admin-to-new-groups/#topic

    though, i don’t know if that fixes the original issue with a legacy creator_id (then again, i don’t see any big references to that col – besides logging)

    @jbau

    Participant

    experiencing the same problem with the wrong group count at the group directory page. I have 1 group but it says 5 total and my groups is 3. I’ve installed BP-group management and it also just finds 1 group.

    I tried to switch to the patch files from https://trac.buddypress.org/ticket/2614 but it only lead to the group count goin down to zero and I was unable to create any new groups. BP-group management then also found no groups. When I went back to the original files I was back to the same problem. 1 actual group, says 5 & 3.

    So I don’t know if I could have done the patching wrong or if this is something that isn’t solveable.

    Is it possible to enter the mysql database and remove the groups from there, to manually update the group count?

    @jbau

    Participant

    Does anyone have a clue how to fix this?

    @nuprn1

    Participant

    have you tried updating to 1.2.6 now?

    @jbau

    Participant

    Yepp I’ve updated and the count for groups is still off by much

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Why Does Group Count Not Go Down When You Delete Group’ is closed to new replies.
Skip to toolbar