WordPress.org

Make WordPress Core

Changeset 17259


Ignore:
Timestamp:
01/11/11 21:00:23 (3 years ago)
Author:
nacin
Message:

Only rely on is_super_admin for is_multisite when generating menu code. fixes #16184.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/menu.php

    r17219 r17259  
    170170 
    171171$menu_perms = get_site_option('menu_items', array()); 
    172 if ( is_super_admin() || ( is_multisite() && isset($menu_perms['plugins']) && $menu_perms['plugins'] ) ) { 
     172if ( ! is_multisite() || ! empty( $menu_perms['plugins'] ) ) { 
    173173    $count = "<span class='update-plugins count-$update_count'><span class='plugin-count'>" . number_format_i18n($update_count) . "</span></span>"; 
    174174    if ( is_multisite() ) 
     
    207207    if ( is_multisite() && !is_main_site() ) 
    208208        $submenu['tools.php'][25] = array( __('Delete Site'), 'manage_options', 'ms-delete-site.php' ); 
    209     if ( ! is_multisite() && defined('WP_ALLOW_MULTISITE') && WP_ALLOW_MULTISITE && is_super_admin() ) 
     209    if ( ! is_multisite() && defined('WP_ALLOW_MULTISITE') && WP_ALLOW_MULTISITE ) 
    210210        $submenu['tools.php'][50] = array(__('Network'), 'manage_options', 'network.php'); 
    211211 
Note: See TracChangeset for help on using the changeset viewer.