Multisite: Introduce an upgrade_network capability.

Prior to this change, a mix of `is_super_admin()` calls and `manage_network` capability checks was used to determine whether the current user could upgrade the network. With this changeset a dedicated capability is introduced that allows more granular handling.

Props dhanendran for the original patch.
Fixes #39205. See #37616.


git-svn-id: https://develop.svn.wordpress.org/trunk@40404 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Felix Arntz
2017-04-10 21:10:48 +00:00
parent 7ddf1b3ce1
commit 1abf42b45e
5 changed files with 7 additions and 3 deletions
+1 -1
View File
@@ -19,7 +19,7 @@ if ( $update_data['counts']['total'] ) {
$submenu['index.php'][10] = array( __( 'Updates' ), 'update_core', 'update-core.php' );
}
$submenu['index.php'][15] = array( __( 'Upgrade Network' ), 'manage_network', 'upgrade.php' );
$submenu['index.php'][15] = array( __( 'Upgrade Network' ), 'upgrade_network', 'upgrade.php' );
$menu[4] = array( '', 'read', 'separator1', '', 'wp-menu-separator' );