Skip to:

Opened 6 years ago

Last modified 6 years ago

#7639 new defect (bug)

Reopening #4706: Infinite Redirect Loop when BP_GROUPS_DEFAULT_EXTENSION is changed on Private groups

Reported by: pareshradadiya's profile pareshradadiya Owned by:
Milestone: Awaiting Contributions Priority: normal
Severity: normal Version: 2.9.2
Component: Groups Keywords: needs-patch reporter-feedback


I have set group default extension to a Members tab for a group and there is now redirect loop when non group member try to access the private group.

While redirecting away from a private group, BuddyPress doesn't appending 'home/' to the redirect URL any longer.


Change History (4)

#1 @pareshradadiya
6 years ago

  • Keywords needs-patch added; needs-refresh removed

#2 @DJPaul
6 years ago

  • Keywords reporter-feedback added
  • Milestone changed from Awaiting Review to Under Consideration

Please provide instructions how exactly to configure the group extension like this, so we can test it.

#3 @pareshradadiya
6 years ago

To reproduce, please do the following

  1. Add this constant define( 'BP_GROUPS_DEFAULT_EXTENSION', 'members' ); in wp-config.php
  2. Login as Subscriber user
  3. Navigate to Groups directory
  4. Browse private in which current logged in user is not a member

The issue is, thats there is redirect loop.

BuddyPress try to load default extension Members and since the group is private and current logged in user is not a member of that group, user will be threw back to a group default page(home) which is Members extension in this case and this goes in loop.

Please see this screencast:

#4 @DJPaul
6 years ago

  • Milestone changed from Under Consideration to Future Release

The redirect is being triggered on (that branch of that conditional). $subnav_item item there is:

array(11) {
  string(7) "members"
  string(2) "t3"
  string(30) "http://bpcore.local/groups/t3/"
  &string(27) "groups_screen_group_members"
  string(22) "Members 1"
  string(30) "http://bpcore.local/groups/t3/"
  string(7) "members"

...which is the navigation item set here: ("Only add the members subnav if it's not the home's nav.") -- that makes sense, but I'm lost trying to understand what should be happening where...

It's something to do with the user not allowed to read a Private group's "members" page, but I'm not sure where the redirect should be fixed or how.

Note: See TracTickets for help on using tickets.