[wp-trac] [WordPress Trac] #39204: Replace `is_super_admin()` check with `manage_network_users` cap check in wp-admin/users.php (was: Replace `is_super_admin()` checks with `manage_network` cap checks in wp-admin/users.php)

WordPress Trac noreply at wordpress.org
Fri Dec 9 16:22:11 UTC 2016


#39204: Replace `is_super_admin()` check with `manage_network_users` cap check in
wp-admin/users.php
-------------------------------------+------------------------
 Reporter:  abhishek kaushik         |       Owner:  flixos90
     Type:  enhancement              |      Status:  reviewing
 Priority:  normal                   |   Milestone:  4.8
Component:  Role/Capability          |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-refresh  |     Focuses:  multisite
-------------------------------------+------------------------
Changes (by flixos90):

 * status:  new => reviewing
 * focuses:  administration, multisite => multisite
 * owner:   => flixos90
 * version:  trunk =>
 * milestone:  Awaiting Review => 4.8
 * keywords:   => has-patch needs-refresh
 * type:  defect (bug) => enhancement


Old description:

> This is part of the #37616 task. There are 3 is_super_admin() checks in
> wp-admin/users.php that should be replaced with current_user_can(
> 'manage_network' ).
> See https://core.trac.wordpress.org/ticket/37616#comment:28

New description:

 This is part of the #37616 task. There is 1 is_super_admin() check in wp-
 admin/users.php that should be replaced with `current_user_can(
 'manage_network_users' )`.
 See https://core.trac.wordpress.org/ticket/37616#comment:28

--

Comment:

 Hi @abhishek kaushik, and thanks for the patch! It generally looks good,
 it just does a little too much. Only the first occurrence of
 `is_super_admin()` (in line 125) should be replaced here, the other two
 are already handled in #39063. Would you mind updating your patch
 accordingly? :)

--
Ticket URL: <https://core.trac.wordpress.org/ticket/39204#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list