[buddypress-trac] [BuddyPress Trac] #7717: roles with bp_moderate capability not seeing BP Admin menu pages
buddypress-trac
noreply at wordpress.org
Wed Mar 14 12:09:02 UTC 2018
#7717: roles with bp_moderate capability not seeing BP Admin menu pages
--------------------------+-----------------------------
Reporter: Venutius | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Core | Version: 2.9.3
Severity: normal | Keywords: bp_moderate
--------------------------+-----------------------------
I've been trying to find a solution to allow some roles the ability to
view the BP Admin menu options such as Activity. I've assigned the role
"Editor" the capability of bp_moderate, have confirmed this is being
applied and confirmed that bp_moderate is the required capability to view
the Activity admin page. however this page is still not showing for
Editors.
I've tried several ways of adding this capability, the most recent code is
as follows:
{{{
add_action( 'admin_init', function() {
$editor = get_role( 'editor' );
if ( ! $editor->has_cap( 'bp_moderate' ) ) {
$editor->add_cap( 'bp_moderate' );
}
});`
}}}
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/7717>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list