WordPress.org

Make WordPress Core


Ignore:
Timestamp:
08/12/2017 01:10:24 PM (3 years ago)
Author:
flixos90
Message:

Multisite: Remove references to $wpdb->siteid and use get_current_network_id() instead.

Props sathyapulse, spacedmonkey.
Fixes #41507.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/ms-functions.php

    r41241 r41242  
    7373        if ( is_array( $blogs ) && count( $blogs ) > 0 ) {
    7474            foreach ( (array) $blogs as $blog_id => $blog ) {
    75                 if ( $blog->site_id != $wpdb->siteid )
     75                if ( $blog->site_id != get_current_network_id() )
    7676                    continue;
    7777                $details = get_site( $blog_id );
     
    10901090    }
    10911091
    1092     $blog_id = wpmu_create_blog( $signup->domain, $signup->path, $signup->title, $user_id, $meta, $wpdb->siteid );
     1092    $blog_id = wpmu_create_blog( $signup->domain, $signup->path, $signup->title, $user_id, $meta, get_current_network_id() );
    10931093
    10941094    // TODO: What to do if we create a user but cannot create a blog?
Note: See TracChangeset for help on using the changeset viewer.