Make WordPress Core


Ignore:
Timestamp:
07/09/2015 04:28:42 PM (9 years ago)
Author:
jeremyfelt
Message:

Avoid PHP notice when attempting to edit a site that does not exist.

Show a more explicit error - "The requested site does not exist."

Fixes #32934.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/network/site-users.php

    r32974 r33144  
    5050
    5151$details = get_blog_details( $id );
     52if ( ! $details ) {
     53    wp_die( __( 'The requested site does not exist' ) );
     54}
     55
    5256if ( ! can_edit_network( $details->site_id ) )
    5357    wp_die( __( 'You do not have permission to access this page.' ), 403 );
Note: See TracChangeset for help on using the changeset viewer.