starting at line 140 of bbPress.php the Group slugs are hardcoded as follows...
elseif ($bbld_option['slug'] == 'buddypress') {
if ($type == 'topic') {
$bp_group = str_replace("-forum", "", $forumslug);
$bp_group = str_replace("amp-", "", $bp_group);
$bp_group = str_replace("-amp", "", $bp_group);
if (BP_VERSION >= 1.1) {
$permalink = get_settings('home') . '/groups/' . $bp_group . '/forum/topic/' . $slug;
}
else {
$permalink = get_settings('home') . '/groups/' . $bp_group . '/forum/topic/' . $topicid;
}
}
else {
$bp_group = str_replace("-forum", "", $slug);
$bp_group = str_replace("amp-", "", $bp_group);
$bp_group = str_replace("-amp", "", $bp_group);
$permalink = get_settings('home') . '/groups/' . $bp_group . '/forum/';
}
}
to improve BuddyPress compatibility is would be much better to use the slug definitions as follows...
elseif ($bbld_option['slug'] == 'buddypress') {
if ($type == 'topic') {
$bp_group = str_replace("-forum", "", $forumslug);
$bp_group = str_replace("amp-", "", $bp_group);
$bp_group = str_replace("-amp", "", $bp_group);
if (BP_VERSION >= 1.1) {
$permalink = get_settings('home') . '/'. BP_GROUPS_SLUG . '/' . $bp_group . '/forum/topic/' . $slug;
}
else {
$permalink = get_settings('home') . '/'. BP_GROUPS_SLUG . '/' . $bp_group . '/forum/topic/' . $topicid;
}
}
else {
$bp_group = str_replace("-forum", "", $slug);
$bp_group = str_replace("amp-", "", $bp_group);
$bp_group = str_replace("-amp", "", $bp_group);
$permalink = get_settings('home') . '/'. BP_GROUPS_SLUG . '/' . $bp_group . '/forum/';
}
This fix may be applicable to other parts of the code.
