Make WordPress Core

Ticket #39200: 39200.patch

File 39200.patch, 954 bytes (added by sathyapulse, 8 years ago)
  • src/wp-admin/options.php

     
    7474        }
    7575}
    7676
    77 if ( is_multisite() && ! is_super_admin() && 'update' != $action ) {
     77if ( is_multisite() && ! current_user_can( 'manage_network_options' ) && 'update' != $action ) {
    7878        wp_die(
    7979                '<h1>' . __( 'Cheatin&#8217; uh?' ) . '</h1>' .
    8080                '<p>' . __( 'Sorry, you are not allowed to delete these items.' ) . '</p>',
     
    160160                wp_die( __( '<strong>ERROR</strong>: options page not found.' ) );
    161161
    162162        if ( 'options' == $option_page ) {
    163                 if ( is_multisite() && ! is_super_admin() )
     163                if ( is_multisite() && ! current_user_can( 'manage_network_options' ) )
    164164                        wp_die( __( 'Sorry, you are not allowed to modify unregistered settings for this site.' ) );
    165165                $options = explode( ',', wp_unslash( $_POST[ 'page_options' ] ) );
    166166        } else {