[buddypress-trac] [BuddyPress Trac] #5812: BP_Group_Extension::_register() should only run if there is a valid group ID

buddypress-trac noreply at wordpress.org
Wed Aug 13 17:46:34 UTC 2014


#5812: BP_Group_Extension::_register() should only run if there is a valid group
ID
--------------------------+------------------
 Reporter:  r-a-y         |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  2.1
Component:  Groups        |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |
--------------------------+------------------

Comment (by r-a-y):

 > A more conservative approach is to bail at the beginning of
 user_meets_access_condition() if $this->group_id is empty. Will that take
 care of the db queries?

 Yup, that works.  However, there is a backward compatibility block before
 that, which does a `groups_get_group()` call.

 Could the group ID check go at the very beginning of the
 `setup_access_settings()` method?

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/5812#comment:3>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list