[buddypress-trac] [BuddyPress Trac] #8355: Site Admins cannot edit BP emails

buddypress-trac noreply at wordpress.org
Sat Sep 5 12:57:41 UTC 2020


#8355: Site Admins cannot edit BP emails
-----------------------------------+---------------------
 Reporter:  shanebp                |       Owner:  DJPaul
     Type:  defect (bug)           |      Status:  new
 Priority:  normal                 |   Milestone:  7.0.0
Component:  Emails                 |     Version:  6.2.0
 Severity:  normal                 |  Resolution:
 Keywords:  has-patch 2nd-opinion  |
-----------------------------------+---------------------

Comment (by boonebgorges):

 This bug shows the weakness in our
 `_bp_enforce_bp_moderate_cap_for_admins()` approach. Our approach assumes
 that WP will always check the `bp_moderate` check directly, but the CPT
 capability mapping is a case where this assumption is incorrect.

 The strategy in [attachment:"8355.patch"] seems to work. But I worry that
 it creates more complexity that will provide difficult to maintain down
 the line. Will we have to add more caps to the 'administrator' role in
 this way in the future? Especially as we leverage more CPTs and taxonomies
 in the future.

 Our current approach was always meant to be a temporary workaround. See
 #4296, [6185]. Can we revisit to see if there is a proper fix?
 Specifically, is it now possible in WP to dynamically filter a role's
 capabilities? If we were able to add 'bp_moderate' to the Administrator
 role, then this problem - and future problems like it - would go away. cc
 @johnjamesjacoby

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


More information about the buddypress-trac mailing list