Remove the GP dashboard for non super admins in GeneratePress

Remove the GP dashboard for non-super admins in GeneratePress on child sites.

Snippet Type

Execute on Child Sites

Snippet

add_filter( 'generate_dashboard_page_capability', 'tu_super_admin_dashboard' );
function tu_super_admin_dashboard() {
  return 'manage_sites';
}
1 Like