Changeset 1492

Show
Ignore:
Timestamp:
09/22/08 15:52:32 (2 months ago)
Author:
donncha
Message:

No need to check the site_id in xmlrpc.php
Use the current_blog for getting user blogs, see #735

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/wp-includes/wpmu-functions.php

    r1462 r1492  
    18611861*/ 
    18621862function wpmu_blogger_getUsersBlogs($args) { 
    1863         $site_details = get_blog_details( 1, true )
    1864         $domain = $site_details->domain; 
    1865         $path = $site_details->path . 'xmlrpc.php'; 
     1863        global $current_blog
     1864        $domain = $current_blog->domain; 
     1865        $path = $current_blog->path . 'xmlrpc.php'; 
    18661866 
    18671867        $rpc = new IXR_Client("http://{$domain}{$path}"); 
  • trunk/xmlrpc.php

    r1344 r1492  
    344344 
    345345                foreach( $blogs as $blog ) { 
    346                         // Don't include blogs that aren't hosted at this site 
    347                         if( $blog->site_id != 1 ) 
    348                                 continue; 
    349  
    350346                        $blog_id = $blog->userblog_id; 
    351347                        switch_to_blog($blog_id); 
     
    359355                                'xmlrpc'                => get_option( 'home' ) . '/xmlrpc.php' 
    360356                        ); 
     357                        restore_current_blog(); 
    361358                } 
    362359