WordPress.org

Make WordPress Core

Ticket #14185: 14185.diff

File 14185.diff, 673 bytes (added by wpmuguru, 4 years ago)
  • wp-admin/ms-sites.php

     
    107107                $blog_prefix = $wpdb->get_blog_prefix( $id ); 
    108108                $options = $wpdb->get_results( "SELECT * FROM {$blog_prefix}options WHERE option_name NOT LIKE '\_%' AND option_name NOT LIKE '%user_roles'" ); 
    109109                $details = get_blog_details( $id ); 
     110                if ( $details->site_id != $wpdb->siteid ) 
     111                        wp_die( __( 'You do not have permission to access this page.' ) ); 
     112 
    110113                $editblog_roles = get_blog_option( $id, "{$blog_prefix}user_roles" ); 
    111114                $is_main_site = is_main_site( $id ); 
    112115                ?>